MCPcopy Index your code
hub / github.com/processing/processing / update

Method update

app/src/processing/app/tools/CreateFont.java:305–325  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

303
304
305 public void update() {
306 int fontsize = 0;
307 try {
308 fontsize = Integer.parseInt(sizeSelector.getText().trim());
309 //System.out.println("'" + sizeSelector.getText() + "'");
310 } catch (NumberFormatException e2) { }
311
312 // if a deselect occurred, selection will be -1
313 if ((fontsize > 0) && (fontsize < 256) && (selection != -1)) {
314 //font = new Font(list[selection], Font.PLAIN, fontsize);
315 Font instance = table.get(list[selection]);
316// font = instance.deriveFont(Font.PLAIN, fontsize);
317 font = instance.deriveFont((float) fontsize);
318 //System.out.println("setting font to " + font);
319 sample.setFont(font);
320
321 String filenameSuggestion = list[selection].replace(' ', '_');
322 filenameSuggestion += "-" + fontsize;
323 filenameField.setText(filenameSuggestion);
324 }
325 }
326
327
328 public void build() {

Callers 4

valueChangedMethod · 0.95
insertUpdateMethod · 0.95
removeUpdateMethod · 0.95
actionPerformedMethod · 0.95

Calls 6

parseIntMethod · 0.80
getMethod · 0.65
trimMethod · 0.45
getTextMethod · 0.45
replaceMethod · 0.45
setTextMethod · 0.45

Tested by

no test coverage detected