Label Stacks

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Label Stacks

Knecht, David
In Label Stacks, what determines the font and style if the "use text tool font" is unchecked?  
What command would set this in a macro?

Visiting Professor David Knecht
Beatson Institute for Cancer Research
University of Glasgow
Switchback Road, Bearsden
Glasgow Scotland G61 1BD
UK






--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: Label Stacks

Rasband, Wayne (NIH/NIMH) [E]
On Jun 10, 2012, at 8:18 AM, David Knecht wrote:

> In Label Stacks, what determines the font and style if the "use text tool font" is unchecked?  
> What command would set this in a macro?

The Image>Stacks>Label command uses "SansSerif" and PLAIN if "Use text tool font" is unchecked, otherwise it uses the font and style defined in the Edit>Options>Fonts dialog box. Here is a macro example that sets the font to "Times" and the style to BOLD+ITALIC:

 newImage("Untitled", "8-bit Black", 500, 500, 100);
 style = 3; // Font.BOLD+Font.ITALIC;
 call("ij.gui.TextRoi.setFont", "Times", 80, style)
 run("Label...", "format=0000 x=50 y=200 font=80 text=Image use use_text");

-wayne

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: Label Stacks

Tiago Ferreira-2
In reply to this post by Knecht, David
On 2012.06.10, at 08:18, David Knecht wrote:
> In Label Stacks, what determines the font and style if the "use text tool
> font" is unchecked?

IJ's default font: Regular sans-serif (cf eg, Stack>Make Montage, Overlays>
labels). Size is 18 unless a rectangular selection exists. In this case is the
ROI's height. (BTW, input values <7 and >80 are ignored).

Unless your question is: What is Java's default sans typeface?
I am no typography expert but it looks Lucida Sans to me. You could check what
fonts you have installed in your jre/lib/font directory.

HTH,
-tiago
--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html