summaryrefslogtreecommitdiff
path: root/examples/gui/fontselect
diff options
context:
space:
mode:
authorgraemeg <graemeg@ae50a9b5-8222-0410-bf8d-8a13f76226bf>2008-03-02 18:43:16 +0000
committergraemeg <graemeg@ae50a9b5-8222-0410-bf8d-8a13f76226bf>2008-03-02 18:43:16 +0000
commitfb373b3dc439a6f6c37ac4a734072fd8beeb244d (patch)
tree002bf6fc9518636865207064f3b65f5d5ff3b1d9 /examples/gui/fontselect
parent529bd6b7079fac487f310e3f88bd37581df1ccbf (diff)
downloadfpGUI-fb373b3dc439a6f6c37ac4a734072fd8beeb244d.tar.xz
* Applications resourcestring declarations do not have to be in a hard-coded filename anymore.
* FontSelect example now has Afrikaans and Russian translation files independent of the fpGUI toolkit translations. A more specific translation demo will be created soon.
Diffstat (limited to 'examples/gui/fontselect')
-rw-r--r--examples/gui/fontselect/fontselect.af_ZA.po27
-rw-r--r--examples/gui/fontselect/fontselect.lpi7
-rw-r--r--examples/gui/fontselect/fontselect.lpr12
-rw-r--r--examples/gui/fontselect/fontselect.ru.po26
-rw-r--r--examples/gui/fontselect/strconstants.pas14
5 files changed, 62 insertions, 24 deletions
diff --git a/examples/gui/fontselect/fontselect.af_ZA.po b/examples/gui/fontselect/fontselect.af_ZA.po
new file mode 100644
index 00000000..07a13d9f
--- /dev/null
+++ b/examples/gui/fontselect/fontselect.af_ZA.po
@@ -0,0 +1,27 @@
+# translation of PACKAGE.
+# Copyright (C) 2008 Free Software Foundation, Inc.
+# <>, 2008.
+#
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2008-03-01 16:54+0200\n"
+"PO-Revision-Date: 2008-03-01 16:55+0200\n"
+"Last-Translator: <>\n"
+"Language-Team: \n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: "
+
+#: fontselect:rsmytitle
+msgid "Font selection test"
+msgstr "Lettertipe keuse toets"
+
+#: fontselect:rsmyfontlist
+msgid "Font List"
+msgstr "Lettertipe Lys"
+
+
diff --git a/examples/gui/fontselect/fontselect.lpi b/examples/gui/fontselect/fontselect.lpi
index 9e24bba9..d97b57fa 100644
--- a/examples/gui/fontselect/fontselect.lpi
+++ b/examples/gui/fontselect/fontselect.lpi
@@ -32,17 +32,12 @@
<MinVersion Minor="5" Valid="True"/>
</Item1>
</RequiredPackages>
- <Units Count="2">
+ <Units Count="1">
<Unit0>
<Filename Value="fontselect.lpr"/>
<IsPartOfProject Value="True"/>
<UnitName Value="fontselect"/>
</Unit0>
- <Unit1>
- <Filename Value="strconstants.pas"/>
- <IsPartOfProject Value="True"/>
- <UnitName Value="strconstants"/>
- </Unit1>
</Units>
</ProjectOptions>
<CompilerOptions>
diff --git a/examples/gui/fontselect/fontselect.lpr b/examples/gui/fontselect/fontselect.lpr
index ce5e301a..a93175ce 100644
--- a/examples/gui/fontselect/fontselect.lpr
+++ b/examples/gui/fontselect/fontselect.lpr
@@ -14,8 +14,12 @@ uses
gui_listbox,
gui_edit,
gui_label,
- gfx_constants,
- strconstants;
+ gfx_constants;
+
+
+resourcestring
+ rsMyTitle = 'Font selection test';
+ rsMyFontList = 'Font List';
type
@@ -65,7 +69,7 @@ end;
constructor TMainForm.Create(AOwner: TComponent);
begin
inherited Create(AOwner);
- WindowTitle := rsTitle;
+ WindowTitle := rsMyTitle;
SetPosition(100, 100, 500, 400);
btnSelectFont := CreateButton(self, 10, 10, 110, rsSelectAFont, @btnSelectFontClick);
@@ -74,7 +78,7 @@ begin
// edFontDesc.Text := fpgApplication.DefaultFont.FontDesc;
edFontDesc.Text := 'Bitstream Vera Sans-9';
- lblFontList := CreateLabel(self, 10, 80, 'Font List:');
+ lblFontList := CreateLabel(self, 10, 80, rsMyFontList + ':');
lbFontList := TfpgListBox.Create(self);
with lbFontList do
begin
diff --git a/examples/gui/fontselect/fontselect.ru.po b/examples/gui/fontselect/fontselect.ru.po
new file mode 100644
index 00000000..c9516536
--- /dev/null
+++ b/examples/gui/fontselect/fontselect.ru.po
@@ -0,0 +1,26 @@
+# translation of PACKAGE.
+# Copyright (C) 2008 Free Software Foundation, Inc.
+# <>, 2008.
+#
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2008-03-01 16:54+0200\n"
+"PO-Revision-Date: 2008-03-01 16:55+0200\n"
+"Last-Translator: <>\n"
+"Language-Team: \n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: "
+
+#: fontselect:rsmytitle
+msgid "Font selection test"
+msgstr "Выбор шрифта испытания"
+
+#: fontselect:rsmyfontlist
+msgid "Font List"
+msgstr "Список шрифтов"
+
diff --git a/examples/gui/fontselect/strconstants.pas b/examples/gui/fontselect/strconstants.pas
deleted file mode 100644
index 15151839..00000000
--- a/examples/gui/fontselect/strconstants.pas
+++ /dev/null
@@ -1,14 +0,0 @@
-unit strconstants;
-
-{$mode objfpc}{$H+}
-
-interface
-
-resourcestring
- rsTitle = 'Font selection test';
-
-
-implementation
-
-end.
-