MCPcopy Create free account
hub / github.com/AstroImageJ/astroimagej / setLabelFontSize

Method setLabelFontSize

ij/src/main/java/ij/gui/Overlay.java:425–435  ·  view source on GitHub ↗

Set the label font size with options. The options string can contain 'scale' (enlarge labels when image zoomed), 'bold' (display bold labels) or 'background' (display labels with contrasting background.

(int size, String options)

Source from the content-addressed store, hash-verified

423 * with contrasting background.
424 */
425 public void setLabelFontSize(int size, String options) {
426 int style = Font.PLAIN;
427 if (options!=null) {
428 scalableLabels = options.contains("scale");
429 if (options.contains("bold"))
430 style = Font.BOLD;
431 drawBackgrounds = options.contains("back");
432 }
433 labelFont = new Font("SansSerif", style, size);
434 drawLabels(true);
435 }
436
437 public Font getLabelFont() {
438 return labelFont;

Callers 1

doOverlayMethod · 0.95

Calls 2

drawLabelsMethod · 0.95
containsMethod · 0.45

Tested by

no test coverage detected