look into selecting font; find failure

This commit is contained in:
Ben Fry
2013-06-01 15:24:37 -04:00
parent ae60d75094
commit 9578cea2de
2 changed files with 19 additions and 2 deletions

View File

@@ -300,6 +300,22 @@ public class Preferences {
Font editorFont = Preferences.getFont("editor.font");
fontSizeField.setText(String.valueOf(editorFont.getSize()));
top += d.height + GUI_BETWEEN;
// Nevermind on this for now.. Java doesn't seem to have a method for
// enumerating only the fixed-width (monospaced) fonts. To do this
// properly, we'd need to list the fonts, and compare the metrics of
// i and M for each. When they're identical (and not degenerate),
// we'd call that font fixed width. That's all a very expensive set of
// operations, so it should also probably be cached between runs and
// updated in the background.
// // Editor font
//
// GraphicsEnvironment ge =
// GraphicsEnvironment.getLocalGraphicsEnvironment();
// Font fonts[] = ge.getAllFonts();
// ArrayList<Font> monoFonts = new ArrayList<Font>();
// [ ] Use smooth text in editor window

View File

@@ -610,8 +610,9 @@ _ when are prefs saved? could instead save whenever changes are made
_ and then if the file gets modified, it'll put up an error message
_ also, this may be part of why other sketches aren't reloading properly
_ control text size in console
_ why aren't prefs from theme.txt showing up in preferences.txt? hrm
_ or rather, why can't they be overridden?
o why aren't prefs from theme.txt showing up in preferences.txt? hrm
o or rather, why can't they be overridden?
X because theme.txt data is a different animal / that's part of the point
_ should fonts at least be in prefs.txt?
_ http://code.google.com/p/processing/issues/detail?id=226
_ simple prefs implementation to set key/value pairs using a JTable