mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-21 03:39:18 +02:00
LazDE doceditor: localized Options dialog (patch from alexs)
git-svn-id: trunk@23970 -
This commit is contained in:
parent
4b739cb16f
commit
85734252cb
@ -301,15 +301,16 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMainForm.AExtraOptionsExecute(Sender: TObject);
|
procedure TMainForm.AExtraOptionsExecute(Sender: TObject);
|
||||||
|
var
|
||||||
|
OptionsForm: TOptionsForm;
|
||||||
begin
|
begin
|
||||||
if Sender=nil then ;
|
OptionsForm:=TOptionsForm.Create(Self);
|
||||||
With TOptionsForm.Create(Self) do
|
try
|
||||||
Try
|
if OptionsForm.ShowModal=mrOk then
|
||||||
if ShowModal=mrOk then
|
ApplyOptions;
|
||||||
ApplyOptions;
|
finally
|
||||||
finally
|
OptionsForm.Free;
|
||||||
Free;
|
end;
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMainForm.AFormatParagraphHint(var HintStr: string;
|
procedure TMainForm.AFormatParagraphHint(var HintStr: string;
|
||||||
|
@ -2,30 +2,31 @@ object OptionsForm: TOptionsForm
|
|||||||
Left = 350
|
Left = 350
|
||||||
Height = 367
|
Height = 367
|
||||||
Top = 262
|
Top = 262
|
||||||
Width = 526
|
Width = 548
|
||||||
HorzScrollBar.Page = 397
|
HorzScrollBar.Page = 397
|
||||||
VertScrollBar.Page = 336
|
VertScrollBar.Page = 336
|
||||||
ActiveControl = PageControl1
|
ActiveControl = PageControl1
|
||||||
BorderStyle = bsDialog
|
|
||||||
Caption = 'Options'
|
Caption = 'Options'
|
||||||
ClientHeight = 367
|
ClientHeight = 367
|
||||||
ClientWidth = 526
|
ClientWidth = 548
|
||||||
OnClose = FormClose
|
OnClose = FormClose
|
||||||
|
OnCreate = FormCreate
|
||||||
OnShow = OptionsFormShow
|
OnShow = OptionsFormShow
|
||||||
|
Position = poScreenCenter
|
||||||
LCLVersion = '0.9.29'
|
LCLVersion = '0.9.29'
|
||||||
object PageControl1: TPageControl
|
object PageControl1: TPageControl
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 315
|
Height = 313
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 526
|
Width = 548
|
||||||
ActivePage = tabGeneral
|
ActivePage = tabGeneral
|
||||||
Align = alClient
|
Align = alClient
|
||||||
TabIndex = 0
|
TabIndex = 0
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object tabGeneral: TTabSheet
|
object tabGeneral: TTabSheet
|
||||||
Caption = 'General'
|
Caption = 'General'
|
||||||
ClientHeight = 284
|
ClientHeight = 282
|
||||||
ClientWidth = 522
|
ClientWidth = 544
|
||||||
object LEBackupExtension: TLabel
|
object LEBackupExtension: TLabel
|
||||||
AnchorSideLeft.Control = LEDefaultExtension
|
AnchorSideLeft.Control = LEDefaultExtension
|
||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideLeft.Side = asrBottom
|
||||||
@ -33,7 +34,7 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 158
|
Left = 158
|
||||||
Height = 18
|
Height = 18
|
||||||
Top = 101
|
Top = 106
|
||||||
Width = 125
|
Width = 125
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Left = 24
|
BorderSpacing.Left = 24
|
||||||
@ -50,7 +51,7 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 313
|
Left = 313
|
||||||
Height = 18
|
Height = 18
|
||||||
Top = 101
|
Top = 106
|
||||||
Width = 120
|
Width = 120
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Left = 24
|
BorderSpacing.Left = 24
|
||||||
@ -65,7 +66,7 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 18
|
Height = 18
|
||||||
Top = 101
|
Top = 106
|
||||||
Width = 122
|
Width = 122
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
@ -79,7 +80,7 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 18
|
Height = 18
|
||||||
Top = 160
|
Top = 163
|
||||||
Width = 129
|
Width = 129
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
@ -94,7 +95,7 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 18
|
Height = 18
|
||||||
Top = 219
|
Top = 220
|
||||||
Width = 102
|
Width = 102
|
||||||
Alignment = taRightJustify
|
Alignment = taRightJustify
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
@ -107,8 +108,8 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Control = LEBackupExtension
|
AnchorSideTop.Control = LEBackupExtension
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 164
|
Left = 164
|
||||||
Height = 29
|
Height = 27
|
||||||
Top = 125
|
Top = 130
|
||||||
Width = 119
|
Width = 119
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
@ -119,7 +120,7 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 319
|
Left = 319
|
||||||
Height = 27
|
Height = 27
|
||||||
Top = 125
|
Top = 130
|
||||||
Width = 116
|
Width = 116
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
@ -129,8 +130,8 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Control = LEDefaultExtension
|
AnchorSideTop.Control = LEDefaultExtension
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 12
|
Left = 12
|
||||||
Height = 29
|
Height = 27
|
||||||
Top = 125
|
Top = 130
|
||||||
Width = 116
|
Width = 116
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
TabOrder = 4
|
TabOrder = 4
|
||||||
@ -140,9 +141,9 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Control = LFEMakeskel
|
AnchorSideTop.Control = LFEMakeskel
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 12
|
Left = 12
|
||||||
Height = 29
|
Height = 27
|
||||||
Top = 184
|
Top = 187
|
||||||
Width = 484
|
Width = 506
|
||||||
DialogTitle = 'Select skeleton generator'
|
DialogTitle = 'Select skeleton generator'
|
||||||
DialogOptions = []
|
DialogOptions = []
|
||||||
FilterIndex = 0
|
FilterIndex = 0
|
||||||
@ -160,9 +161,9 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Control = LFEfpdoc
|
AnchorSideTop.Control = LFEfpdoc
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 12
|
Left = 12
|
||||||
Height = 29
|
Height = 27
|
||||||
Top = 243
|
Top = 244
|
||||||
Width = 484
|
Width = 506
|
||||||
DialogTitle = 'Select documentation generator'
|
DialogTitle = 'Select documentation generator'
|
||||||
DialogOptions = []
|
DialogOptions = []
|
||||||
FilterIndex = 0
|
FilterIndex = 0
|
||||||
@ -179,22 +180,22 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideLeft.Control = tabGeneral
|
AnchorSideLeft.Control = tabGeneral
|
||||||
AnchorSideTop.Control = tabGeneral
|
AnchorSideTop.Control = tabGeneral
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 89
|
Height = 94
|
||||||
Top = 6
|
Top = 6
|
||||||
Width = 254
|
Width = 254
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
ClientHeight = 81
|
ClientHeight = 90
|
||||||
ClientWidth = 246
|
ClientWidth = 250
|
||||||
TabOrder = 5
|
TabOrder = 5
|
||||||
object CBSkipEmptyNodes: TCheckBox
|
object CBSkipEmptyNodes: TCheckBox
|
||||||
AnchorSideLeft.Control = GroupBox1
|
AnchorSideLeft.Control = GroupBox1
|
||||||
AnchorSideTop.Control = CBCreateBackup
|
AnchorSideTop.Control = CBCreateBackup
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 19
|
Height = 22
|
||||||
Top = 56
|
Top = 62
|
||||||
Width = 234
|
Width = 238
|
||||||
AllowGrayed = True
|
AllowGrayed = True
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
Caption = '&Skip empty nodes when saving'
|
Caption = '&Skip empty nodes when saving'
|
||||||
@ -205,9 +206,9 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideTop.Control = CBConfirmDelete
|
AnchorSideTop.Control = CBConfirmDelete
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 19
|
Height = 22
|
||||||
Top = 31
|
Top = 34
|
||||||
Width = 129
|
Width = 133
|
||||||
AllowGrayed = True
|
AllowGrayed = True
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
Caption = 'Create &backups'
|
Caption = 'Create &backups'
|
||||||
@ -217,9 +218,9 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideLeft.Control = GroupBox1
|
AnchorSideLeft.Control = GroupBox1
|
||||||
AnchorSideTop.Control = GroupBox1
|
AnchorSideTop.Control = GroupBox1
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 19
|
Height = 22
|
||||||
Top = 6
|
Top = 6
|
||||||
Width = 131
|
Width = 135
|
||||||
AllowGrayed = True
|
AllowGrayed = True
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
Caption = 'C&onfirm deletes'
|
Caption = 'C&onfirm deletes'
|
||||||
@ -235,25 +236,25 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideBottom.Control = GroupBox1
|
AnchorSideBottom.Control = GroupBox1
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 266
|
Left = 266
|
||||||
Height = 89
|
Height = 94
|
||||||
Top = 6
|
Top = 6
|
||||||
Width = 250
|
Width = 272
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Left = 6
|
BorderSpacing.Left = 6
|
||||||
BorderSpacing.Top = 6
|
BorderSpacing.Top = 6
|
||||||
BorderSpacing.Right = 6
|
BorderSpacing.Right = 6
|
||||||
ClientHeight = 81
|
ClientHeight = 90
|
||||||
ClientWidth = 242
|
ClientWidth = 268
|
||||||
TabOrder = 6
|
TabOrder = 6
|
||||||
object CBReopenLast: TCheckBox
|
object CBReopenLast: TCheckBox
|
||||||
AnchorSideLeft.Control = GroupBox2
|
AnchorSideLeft.Control = GroupBox2
|
||||||
AnchorSideTop.Control = CBStartMaximized
|
AnchorSideTop.Control = CBStartMaximized
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 19
|
Height = 22
|
||||||
Top = 31
|
Top = 34
|
||||||
Width = 202
|
Width = 206
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
Caption = 'Reopen last file on startup'
|
Caption = 'Reopen last file on startup'
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
@ -262,9 +263,9 @@ object OptionsForm: TOptionsForm
|
|||||||
AnchorSideLeft.Control = GroupBox2
|
AnchorSideLeft.Control = GroupBox2
|
||||||
AnchorSideTop.Control = GroupBox2
|
AnchorSideTop.Control = GroupBox2
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 19
|
Height = 22
|
||||||
Top = 6
|
Top = 6
|
||||||
Width = 129
|
Width = 133
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
Caption = 'Start maximized'
|
Caption = 'Start maximized'
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
@ -273,15 +274,15 @@ object OptionsForm: TOptionsForm
|
|||||||
end
|
end
|
||||||
object tabDesktop: TTabSheet
|
object tabDesktop: TTabSheet
|
||||||
Caption = 'Desktop'
|
Caption = 'Desktop'
|
||||||
ClientHeight = 284
|
ClientHeight = 282
|
||||||
ClientWidth = 522
|
ClientWidth = 544
|
||||||
object CBShowHints: TCheckBox
|
object CBShowHints: TCheckBox
|
||||||
AnchorSideLeft.Control = tabDesktop
|
AnchorSideLeft.Control = tabDesktop
|
||||||
AnchorSideTop.Control = tabDesktop
|
AnchorSideTop.Control = tabDesktop
|
||||||
Left = 14
|
Left = 6
|
||||||
Height = 19
|
Height = 22
|
||||||
Top = 12
|
Top = 6
|
||||||
Width = 97
|
Width = 101
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
Caption = 'Show Hints'
|
Caption = 'Show Hints'
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
@ -290,9 +291,9 @@ object OptionsForm: TOptionsForm
|
|||||||
end
|
end
|
||||||
object ButtonPanel1: TButtonPanel
|
object ButtonPanel1: TButtonPanel
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 40
|
Height = 42
|
||||||
Top = 321
|
Top = 319
|
||||||
Width = 514
|
Width = 536
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
ShowButtons = [pbOK, pbCancel, pbHelp]
|
ShowButtons = [pbOK, pbCancel, pbHelp]
|
||||||
end
|
end
|
||||||
|
@ -58,6 +58,7 @@ type
|
|||||||
tabGeneral: TTabSheet;
|
tabGeneral: TTabSheet;
|
||||||
tabDesktop: TTabSheet;
|
tabDesktop: TTabSheet;
|
||||||
procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
|
procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
procedure OptionsFormShow(Sender: TObject);
|
procedure OptionsFormShow(Sender: TObject);
|
||||||
private
|
private
|
||||||
{ private declarations }
|
{ private declarations }
|
||||||
@ -67,12 +68,9 @@ type
|
|||||||
procedure FormToOptions;
|
procedure FormToOptions;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
var
|
|
||||||
OptionsForm: TOptionsForm;
|
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
uses LazDEOpts;
|
uses LazDEOpts, LazDEMsg;
|
||||||
|
|
||||||
{$R *.lfm}
|
{$R *.lfm}
|
||||||
|
|
||||||
@ -90,6 +88,24 @@ begin
|
|||||||
FormToOptions;
|
FormToOptions;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TOptionsForm.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
Caption:=sOptDlgOptions;
|
||||||
|
tabGeneral.Caption:=sOptDlgGeneral;
|
||||||
|
tabDesktop.Caption:=sOptDlgDesktop;
|
||||||
|
CBShowHints.Caption:=sOptDlgShowHints;
|
||||||
|
CBConfirmDelete.Caption:=sOptDlgConfirmDeletes;
|
||||||
|
CBCreateBackup.Caption:=sOptDlgCreateBackups;
|
||||||
|
CBSkipEmptyNodes.Caption:=sOptDlgSkipEmptyNodes;
|
||||||
|
CBStartMaximized.Caption:=sOptDlgStartMaximized;
|
||||||
|
CBReopenLast.Caption:=sOptDlgReopenLastFile;
|
||||||
|
LEDefaultExtension.Caption:=sOptDlgDefaultExtension;
|
||||||
|
LEBackupExtension.Caption:=sOptDlgBackupExtension;
|
||||||
|
LEMaxMRU.Caption:=sOptDlgMaxRecentUsed;
|
||||||
|
LFEMakeskel.Caption:=sOptDlgMakeskelProgram;
|
||||||
|
LFEfpdoc.Caption:=sOptDlgFpdocProgram;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TOptionsForm.optionstoform;
|
procedure TOptionsForm.optionstoform;
|
||||||
begin
|
begin
|
||||||
CBCreateBackup.Checked:=CreateBackup;
|
CBCreateBackup.Checked:=CreateBackup;
|
||||||
|
@ -226,6 +226,22 @@ ResourceString
|
|||||||
//SOpenFileTitle = 'Select file to open';
|
//SOpenFileTitle = 'Select file to open';
|
||||||
sSelectSomeText = 'Select some text';
|
sSelectSomeText = 'Select some text';
|
||||||
|
|
||||||
|
//Options dialog
|
||||||
|
sOptDlgOptions = 'Options';
|
||||||
|
sOptDlgGeneral = 'General';
|
||||||
|
sOptDlgDesktop = 'Desktop';
|
||||||
|
sOptDlgShowHints = 'Show hints';
|
||||||
|
sOptDlgConfirmDeletes = 'C&onfirm deletes';
|
||||||
|
sOptDlgCreateBackups = 'Create &backups';
|
||||||
|
sOptDlgSkipEmptyNodes = '&Skip empty nodes when saving';
|
||||||
|
sOptDlgStartMaximized = 'Start maximized';
|
||||||
|
sOptDlgReopenLastFile = 'Reopen last file on startup';
|
||||||
|
sOptDlgDefaultExtension= 'Default extension';
|
||||||
|
sOptDlgBackupExtension = 'Backup extension';
|
||||||
|
sOptDlgMaxRecentUsed = 'Max. recent used';
|
||||||
|
sOptDlgMakeskelProgram = 'makeskel program';
|
||||||
|
sOptDlgFpdocProgram = 'fpdoc program';
|
||||||
|
|
||||||
Function FormatHint(S : String) : String;
|
Function FormatHint(S : String) : String;
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
Loading…
Reference in New Issue
Block a user