[Lazarus] IDE Font issue

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[Lazarus] IDE Font issue

Michael Van Canneyt
Hi,

I attached a small image of the SQL editor of TSQLQuery.
Lazarus version of today.

The code in sqlstringspropertyeditordlg.pas (components/sqldb):

constructor TSQLStringsPropertyEditorDlg.Create(AOwner: TComponent);
begin
   inherited Create(AOwner);
   SourceEditorManagerIntf.GetEditorControlSettings(SQLEditor);
   SourceEditorManagerIntf.GetHighlighterSettings(SQLHighlighter);
   EditorTabSheet.Caption := SSQLTabCaption;
   ResultTabSheet.Caption := SResultTabCaption;
end;

Suggests that the font in the SQL property editor should be the
same as the source editor font. From the attached image, it is
clear that they are different.
(Probably it is the same typeface, but the font in the SQL editor
is much smaller as in the source editor)

I assume this is a bug ? How can I fix this ?

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

font.png (16K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] IDE Font issue

zeljko
On Monday 21 of February 2011 16:08:34 Michael Van Canneyt wrote:

> Hi,
>
> I attached a small image of the SQL editor of TSQLQuery.
> Lazarus version of today.
>
> The code in sqlstringspropertyeditordlg.pas (components/sqldb):
>
> constructor TSQLStringsPropertyEditorDlg.Create(AOwner: TComponent);
> begin
>    inherited Create(AOwner);
>    SourceEditorManagerIntf.GetEditorControlSettings(SQLEditor);
>    SourceEditorManagerIntf.GetHighlighterSettings(SQLHighlighter);
>    EditorTabSheet.Caption := SSQLTabCaption;
>    ResultTabSheet.Caption := SResultTabCaption;
> end;
>
> Suggests that the font in the SQL property editor should be the
> same as the source editor font. From the attached image, it is
> clear that they are different.
> (Probably it is the same typeface, but the font in the SQL editor
> is much smaller as in the source editor)
>
> I assume this is a bug ? How can I fix this ?

hm...looks like mismatch between Font.Size and Font.Height

zeljko

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] IDE Font issue

Michael Van Canneyt


On Mon, 21 Feb 2011, zeljko wrote:

> On Monday 21 of February 2011 16:08:34 Michael Van Canneyt wrote:
>> Hi,
>>
>> I attached a small image of the SQL editor of TSQLQuery.
>> Lazarus version of today.
>>
>> The code in sqlstringspropertyeditordlg.pas (components/sqldb):
>>
>> constructor TSQLStringsPropertyEditorDlg.Create(AOwner: TComponent);
>> begin
>>    inherited Create(AOwner);
>>    SourceEditorManagerIntf.GetEditorControlSettings(SQLEditor);
>>    SourceEditorManagerIntf.GetHighlighterSettings(SQLHighlighter);
>>    EditorTabSheet.Caption := SSQLTabCaption;
>>    ResultTabSheet.Caption := SResultTabCaption;
>> end;
>>
>> Suggests that the font in the SQL property editor should be the
>> same as the source editor font. From the attached image, it is
>> clear that they are different.
>> (Probably it is the same typeface, but the font in the SQL editor
>> is much smaller as in the source editor)
>>
>> I assume this is a bug ? How can I fix this ?
>
> hm...looks like mismatch between Font.Size and Font.Height

Yes, you said this last time I reported it, but nothing changed :)

But how to fix it ? Is it a bug in GetEditorControlSettings ?
I assume so, because it definitely overrides the settings I set in the dialog
form file.

As far as I can see, it ends up in editoroptions.pp:

procedure TEditorOptions.ApplyFontSettingsTo(ASynEdit: TSynEdit);
begin
   ASynEdit.Font.Height := fEditorFontHeight;// set height before name for XLFD !
   ASynEdit.Font.Name := fEditorFont;
   if fDisableAntialiasing then
     ASynEdit.Font.Quality := fqNonAntialiased
   else
     ASynEdit.Font.Quality := fqDefault;
end;

Is this a buggy procedure ?

Michael.

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] IDE Font issue

Martin Frb
On 21/02/2011 15:29, Michael Van Canneyt wrote:

>
>
> On Mon, 21 Feb 2011, zeljko wrote:
>
>> hm...looks like mismatch between Font.Size and Font.Height
>
> Yes, you said this last time I reported it, but nothing changed :)
>
> But how to fix it ? Is it a bug in GetEditorControlSettings ?
> I assume so, because it definitely overrides the settings I set in the
> dialog
> form file.

hm where is that bug? Make sure to add
http://bugs.freepascal.org/view.php?id=17694 as related....

Because whenever http://bugs.freepascal.org/view.php?id=17694 gets
fixed, it must make sure not to break this one....



--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] IDE Font issue

Michael Van Canneyt


On Mon, 21 Feb 2011, Martin wrote:

> On 21/02/2011 15:29, Michael Van Canneyt wrote:
>>
>>
>> On Mon, 21 Feb 2011, zeljko wrote:
>>
>>> hm...looks like mismatch between Font.Size and Font.Height
>>
>> Yes, you said this last time I reported it, but nothing changed :)
>>
>> But how to fix it ? Is it a bug in GetEditorControlSettings ?
>> I assume so, because it definitely overrides the settings I set in the
>> dialog
>> form file.
>
> hm where is that bug? Make sure to add
> http://bugs.freepascal.org/view.php?id=17694 as related....

http://bugs.freepascal.org/view.php?id=18795

Marked 17694 as related.

Incidentally, I could not find any font-related settings in the XML config files.

Michael.

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus