Login  Register

Re: Fonts too small

Posted by Krs5 on Jan 16, 2019; 8:58am
URL: http://imagej.273.s1.nabble.com/Fonts-too-small-tp5021640p5021650.html

Hi Curtis, Wayne, Gabriel

This is interesting. Due to the fact that I have some additional items in the menu bar (BAR and ThreeDViewer) I have to resize my GUI every time when I restart Fiji. This script could do it automatically. So I have saved it as a *.js file in the macro folder and added a line to the Edit > Options > Startup.. to do this.

In my case the code is: runMacro("Z:\\program files\\Fiji.app\\macros\\Startup_resize.js");

It works if I add it and close the Startup menu. It executes the code in this window and the GUI is resized. However, if I restart Fiji, it does not resize the GUI and there is no error message. If I go back to the Startup.. menu window, make a change (extra return) and close this menu it execute this again and runs the script correctly. So it seems to work, but fails at startup .

Best wishes

Kees


Dr Ir K.R. Straatman
Senior Experimental Officer
Advanced Imaging Facility
Centre for Core Biotechnology Services
University of Leicester
www.le.ac.uk/advanced-imaging-facility


-----Original Message-----
From: ImageJ Interest Group <[hidden email]> On Behalf Of Curtis Rueden
Sent: 15 January 2019 21:04
To: [hidden email]
Subject: Re: Fonts too small

Hi Gabriel,

> Perhaps making the main window expandable again would allow resizing
> it to taste, but maybe there is a good reason to have it fixed.

Interesting. I tested this (Xubuntu with Xfce in a VM, plain ImageJ 1.52a), and found the window could not be resized; the window moves instead of resizing when grabbing an edge. Whereas with Fiji (with ImageJ 2.0.0-rc-69 / 1.52i) I am able to resize by grabbing the window edges. Launching that same Fiji installation with the "--ij1" option also results in an ImageJ window that cannot be resized for me.

The following JavaScript code will resize the main window directly:

  importClass(Packages.ij.IJ)
  importClass(Packages.java.awt.Dimension)
  IJ.getInstance().setSize(new Dimension(850, 350))

You can run it with Plugins > New > Javascript, or the Script Editor, or Script Interpreter, or whatever code execution method you like.

I am not able to reproduce your HiDPI issue on my Ubuntu Linux VM, but that might be due to VirtualBox's display handling—I don't think my Linux desktop considers itself to be running in a HiDPI environment within VirtualBox.

Regards,
Curtis

--
Curtis Rueden
LOCI software architect - https://loci.wisc.edu/software
ImageJ2 lead, Fiji maintainer - https://imagej.net/User:Rueden Have you tried the Image.sc Forum? https://forum.image.sc/



On Tue, Jan 15, 2019 at 8:35 AM Gabriel Landini <[hidden email]>
wrote:

> On Tuesday, 15 January 2019 12:53:57 GMT you wrote:
> > concerning the main ImageJ Panel:
> > I think here it is the font size in points and not the Scale factor
> > from the Appearance options that applies.
>
> Hi Michael.
> Yes, that is right and beyond 24 font size it does not seem to make a
> difference.
>
> > As a workaround, you can extend the size of the main ImageJ panel by
> > loading more Tools in your StartupMacros.
>
> Will try that. Unfortunately the icons are too small anyway, so I
> would have to add a ton of icons tools. Perhaps making the main window
> expandable again would allow resizing it to taste, but maybe there is
> a good reason to have it fixed.
>
> I found a window manager option to force a window to a given size, but
> then all windows get resized to that size.
> At the moment it appears that reducing the screen resolution is the
> only thing that makes IJ usable again. A pity because this kind of
> defeats the purpose of having a finer screen resolutions.
>
> Regards
>
> Gabriel
>
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>

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

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