Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2011-08

Editor font height in IDE options

11 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

cobines

Hello.

In the IDE there is a combobox where you can choose editor font height. Is it needed by anyone to set height not size? Normally in applications you set font size. I understand the difference between height and size. It may be confusing for someone who doesn't that they are two different ways of setting font size.

At least on Windows and Linux/Gtk2,Qt you can choose size from the font dialog. After I choose a font with a font dialog the combobox text has a negative value, but in the combobox list there are positive values. It's not consistent.
Either use always negative or always positive.

I would be for removing the combobox altogether. I tried to find some information why it is there but I haven't found any.

cobines

Reply by email

Myriam Armengol
to cobines

Hi,

In the IDE there is a combobox where you can choose editor font

Show quoted text 5 lines
height. Is it needed by anyone to set height not size? Normally in applications you set font size. I understand the difference between height and size. It may be confusing for someone who doesn't that they are two different ways of setting font size.

+1
I'd vote for removing the height combobox, it's confusing and unnecessary in a simple text editor. (Publishing is another story)

Gerard.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20110808/c21d6b8b/attachment.html>

Reply by email

Martin
to cobines: Hello. In the IDE there is a combobox where you can choose editor font height. Is it…
cobines wrote 17 lines
Hello. In the IDE there is a combobox where you can choose editor font height. Is it needed by anyone to set height not size? Normally in applications you set font size. I understand the difference between height and size. It may be confusing for someone who doesn't that they are two different ways of setting font size. At least on Windows and Linux/Gtk2,Qt you can choose size from the font dialog. After I choose a font with a font dialog the combobox text has a negative value, but in the combobox list there are positive values. It's not consistent. Either use always negative or always positive. I would be for removing the combobox altogether. I tried to find some information why it is there but I haven't found any.

Is that about ta un-needed drop-down, or about the inconsistency between height and size.

In other words, if the drop-down was size (instead of height) would it still be undesired?
IMHO it's a quicker way to adapt the font size, if one does not want to change the font itself. Because if you want to see the preview, you have to open the dialog, select the size, close the dialog with ok, so the preview synedit shows the font size. (I did definetly use the drop down to try each potential font, in different sizes, and see how it looks ,

The preview in the font dialog itself is not helpful imho.

---------
About the size/height inconsistency => that is known, there even is a bug report.

To fix it, it needs to be analysed what is stored internally and in the editoroptions.xml.

And be ensured that compatibility is kept too.

Reply by email

cobines
to Martin

2011/8/8 Martin :

In other words, if the drop-down was size (instead of height) would it still be undesired?

If it was size it would be useful. It would be consistent to what you set in the dialog and it would be less confusing because there would be only one method of setting size.

Currently, for example, I set font size 18pt in the dialog. I decide it is too small. The height combo says "-29". What value should I put into height to quickly view a bit larger font? I don't want to calculate that :)

So, instead of removing, maybe change it to represent size. (Hence my previous question, does anyone need to set height). In this case I think an edit box with +/- buttons would be more useful than the combo.

cobines

Reply by email

Martin
to cobines
cobines wrote 7 lines
2011/8/8 Martin: > In other words, if the drop-down was size (instead of height) would it still > be undesired? If it was size it would be useful. It would be consistent to what you set in the dialog and it would be less confusing because there would be only one method of setting size.

http://bugs.freepascal.org/view.php?id=17694 AND related issues...

As I said, the hold back, is to check on each widgetset, what affacts what, and what is stored in the options.

Then to make sure all get moved to size => including NEWLY saved options. But to support any old setting and convert them correctly....

Otherwhise, of the options contain height, but the IDE only shows size, other confusion may arise...

AND under no circumstances should a change just reset about everybodies settings....

Reply by email

Reinier Olislagers
to Martin
Martin wrote 8 lines
On 08/08/2011 18:00, cobines wrote: > 2011/8/8 Martin: >> In other words, if the drop-down was size (instead of height) would >> it still >> be undesired? > If it was size it would be useful. It would be consistent to what you > set in the dialog and it would be less confusing because there would > be only one method of setting size.

<snip>

AND under no circumstances should a change just reset about everybodies settings....

Why not? Lazarus is still in beta.

Why not simply provide a reasonable new default for the height and just mention in the release notes that users have to set a new value if they want to...

It's not like it's a breaking API change for the FCL....

My slightly pragmatic two cents,

Reinier

Reply by email

cobines
to Martin: http://bugs.freepascal.org/view.php?id=17694 AND related issues... As I said, the hold…

2011/8/8 Martin :

As I said, the hold back, is to check on each widgetset, what affacts what, and what is stored in the options.

In config file there is EditorFontHeight. It is used in such contexts:

Font.Height:=EditorOpts.EditorFontHeight
   XMLConfig.SetDeleteValue('EditorOptions/Display/EditorFontHeight'
      ,fEditorFontHeight, SynDefaultFontHeight);

To me it is clear it is always the font height saved to config file.

Then to make sure all get moved to size => including NEWLY saved options. But to support any old setting and convert them correctly....

Conversion size<->height as far as I can see is in TFont.SetHeight() and TFont.SetSize().

I'll make a patch so that there is something to test.

cobines

Reply by email

Martin
to cobines: 2011/8/8 Martin : In config file there is EditorFontHeight. It is used in such contexts:…
cobines wrote 20 lines
2011/8/8 Martin: > As I said, the hold back, is to check on each widgetset, what affacts what, > and what is stored in the options. > In config file there is EditorFontHeight. It is used in such contexts: Font.Height:=EditorOpts.EditorFontHeight XMLConfig.SetDeleteValue('EditorOptions/Display/EditorFontHeight' ,fEditorFontHeight, SynDefaultFontHeight); To me it is clear it is always the font height saved to config file. > Then to make sure all get moved to size => including NEWLY saved options. > But to support any old setting and convert them correctly.... Conversion size<->height as far as I can see is in TFont.SetHeight() and TFont.SetSize(). I'll make a patch so that there is something to test.

the editor option files has version numbers.

it only gets new written, if the user makes achange.

the loader must always be able to load the old version, and convert.

But if a user does change his options, then it should write size...

Reply by email

cobines
to Martin

2011/8/9 Martin :

Show quoted text 7 lines
the editor option files has version numbers. it only gets new written, if the user makes achange. the loader must always be able to load the old version, and convert. But if a user does change his options, then it should write size...

I didn't use version. I load EditorFontHeight, if it doesn't exist I load EditorFontSize. On write I delete EditorFontHeight and write EditorFontSize.

cobines

Reply by email

Martin
to cobines
cobines wrote 12 lines
2011/8/9 Martin: > the editor option files has version numbers. > > it only gets new written, if the user makes achange. > > the loader must always be able to load the old version, and convert. > > But if a user does change his options, then it should write size... I didn't use version. I load EditorFontHeight, if it doesn't exist I load EditorFontSize. On write I delete EditorFontHeight and write EditorFontSize.

ok, I will look at it, I am a bit tied up right now

Reply by email