This simple CLX application tries to set font-family of TMemo to fixed-width font:
1. Application compiled using Kylix 3 running in local Linux box gives correct alignment.
2. Application compiled using Delphi 7 running in local Windows box gives correct alignment.
3. Application compiled using Kylix 3 running in remote Linux with Windows XServer does not give correct alignment.
4. Application compiled using Kylix 3 running in remote Linux with Mac Lion XServer does not give correct alignment.
Could you help to comment how to work around this problem? Any comment will be appreciated!
uMainForm.pas
unit uMainForm;
interface
uses
SysUtils, Types, Classes, Variants, QTypes, QGraphics, QControls, QForms,
QDialogs, QStdCtrls;
type
TForm1 = class(TForm)
mmo1: TMemo;
procedure FormCreate(Sender: TObject);
end;
var
Form1: TForm1;
implementation
procedure TForm1.FormCreate(Sender: TObject);
begin
mmo1.Font.Name := 'Console';
end;
{$R *.xfm}
end.
uMainForm.xfm
object Form1: TForm1
Left = 373
Top = 181
Width = 928
Height = 480
VertScrollBar.Range = 185
HorzScrollBar.Range = 305
ActiveControl = mmo1
Caption = 'Form1'
Color = clBackground
OnCreate = FormCreate
PixelsPerInch = 96
TextHeight = 12
TextWidth = 6
object mmo1: TMemo
Left = 120
Top = 96
Width = 185
Height = 89
Lines.Strings = (
'Max'
'001'
'202')
TabOrder = 0
end
end