[Lazarus] IDE Font issue
Michael Van Canneyt
michael at freepascal.org
Mon Feb 21 16:29:26 CET 2011
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.
More information about the Lazarus
mailing list