SlickEdit Community

SlickEdit Product Discussion => SlickEdit® => Topic started by: rowbearto on January 11, 2023, 02:08:25 PM

Title: When using Ctrl+scroll wheel is there a way to see the new font point size ?
Post by: rowbearto on January 11, 2023, 02:08:25 PM
I use ctrl+scroll wheel to change the font size. How to know what the resulting point size is?

I do this in both editor window and in build tool window. How to know the font size for each?

Does this font size persist across restarts of SE?

Does the font size in Tools->Options->Appearance->Fonts get updated when I use Ctrl+scroll wheel? Seems not?

Is the updated font size from Ctrl+scroll wheel used for new windows?
Title: Re: When using Ctrl+scroll wheel is there a way to see the new font point size ?
Post by: patrick on January 11, 2023, 03:48:23 PM
When you change the font size, it's changing a per-window property, called p_font_size.

I don't see a built in way to show that variable.  This shows it:
Code: [Select]
#include "slick.sh"

_command void show_font_size() name_info(','VSARG2_READ_ONLY|VSARG2_REQUIRES_EDITORCTL)
{
   _message_box('Window font size is 'p_font_size);
}

It gets persisted in vrestore.slk, since it's associated with a particular window&buffer.

It can persist across SlickEdit startups if the buffers are restored on startup.  If you've enabled settings so no files are restored on startup, the changes aren't restored.

It is not used for new windows.

Title: Re: When using Ctrl+scroll wheel is there a way to see the new font point size ?
Post by: Clark on January 11, 2023, 05:25:25 PM
Ctrl+scroll wheel is a local font setting for the current window only and is not any kind of global font change.

Window>Font will show you the font for the current edit window. You can choose "All files and global default" if you want to apply this window font to all windows and the global setting (very handy).

The build tool window does not restore the font size. Might be nice if it did.