gotisso-commit Mailing List for Gotisso Meal Planner
Status: Inactive
Brought to you by:
jmvaz
You can subscribe to this list here.
| 2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(7) |
Dec
(13) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(5) |
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <jm...@us...> - 2010-08-23 04:32:10
|
Revision: 25
http://gotisso.svn.sourceforge.net/gotisso/?rev=25&view=rev
Author: jmvaz
Date: 2010-08-23 04:32:04 +0000 (Mon, 23 Aug 2010)
Log Message:
-----------
new directory structure: source relocation
Added Paths:
-----------
src/branches/
src/tags/
src/trunk/
Removed Paths:
-------------
branches/
tags/
trunk/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2010-08-23 04:30:39
|
Revision: 24
http://gotisso.svn.sourceforge.net/gotisso/?rev=24&view=rev
Author: jmvaz
Date: 2010-08-23 04:30:33 +0000 (Mon, 23 Aug 2010)
Log Message:
-----------
new directory structure
Added Paths:
-----------
src/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2010-08-23 04:23:03
|
Revision: 23
http://gotisso.svn.sourceforge.net/gotisso/?rev=23&view=rev
Author: jmvaz
Date: 2010-08-23 04:22:55 +0000 (Mon, 23 Aug 2010)
Log Message:
-----------
Linux test: adding bin/i386-linux dir
Modified Paths:
--------------
trunk/gotisso.lpi
trunk/lang/gotisso.en.po
trunk/lang/gotisso.po
trunk/lang/gotisso.pt_BR.po
Added Paths:
-----------
trunk/bin/i386-linux/
Removed Paths:
-------------
trunk/output/
Property Changed:
----------------
trunk/
Property changes on: trunk
___________________________________________________________________
Modified: svn:ignore
- *.lps
+ gotisso.lps.bak
gotisso.lpi.bak
*.lps
Modified: trunk/gotisso.lpi
===================================================================
--- trunk/gotisso.lpi 2010-08-23 03:55:24 UTC (rev 22)
+++ trunk/gotisso.lpi 2010-08-23 04:22:55 UTC (rev 23)
@@ -1,8 +1,8 @@
<?xml version="1.0"?>
<CONFIG>
<ProjectOptions>
+ <Version Value="9"/>
<PathDelim Value="\"/>
- <Version Value="8"/>
<General>
<Flags>
<SaveClosedFiles Value="False"/>
@@ -10,8 +10,6 @@
<AlwaysBuild Value="False"/>
</Flags>
<SessionStorage Value="InProjectDir"/>
- <MainUnit Value="0"/>
- <TargetFileExt Value=".exe"/>
<Title Value="gotisso"/>
<UseAppBundle Value="False"/>
<ResourceType Value="res"/>
@@ -24,7 +22,6 @@
</i18n>
<VersionInfo>
<Language Value="0416"/>
- <StringTable Comments="" CompanyName="" FileDescription="" FileVersion="0.0.0.0" InternalName="" LegalCopyright="" LegalTrademarks="" OriginalFilename="" ProductName="" ProductVersion="0.0.0.0"/>
</VersionInfo>
<PublishOptions>
<Version Value="2"/>
@@ -35,7 +32,7 @@
<RunParams>
<local>
<FormatVersion Value="1"/>
- <LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
+ <LaunchingApplication PathPlusParams="\usr\X11R6\bin\xterm -T 'Lazarus Run Output' -e $(LazarusDir)\tools\runwait.sh $(TargetCmdLine)"/>
</local>
</RunParams>
<RequiredPackages Count="2">
@@ -137,4 +134,4 @@
<CreateMakefileOnBuild Value="True"/>
</Other>
</CompilerOptions>
-</CONFIG>
+</CONFIG>
Modified: trunk/lang/gotisso.en.po
===================================================================
--- trunk/lang/gotisso.en.po 2010-08-23 03:55:24 UTC (rev 22)
+++ trunk/lang/gotisso.en.po 2010-08-23 04:22:55 UTC (rev 23)
@@ -1,194 +1,194 @@
-msgid ""
-msgstr ""
-"Content-Type: text/plain; charset=UTF-8\n"
-"Project-Id-Version: Gotosso Meal Planner\n"
-"POT-Creation-Date: \n"
-"PO-Revision-Date: \n"
-"Last-Translator: João Marcelo S. Vaz <jm...@gm...>\n"
-"Language-Team: João Marcelo S. Vaz\n"
-"MIME-Version: 1.0\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Poedit-Language: English\n"
-"X-Poedit-Country: UNITED STATES\n"
-
-#: TFMINGREDIENTS.BTCLOSE.CAPTION
-msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
-msgid "Close"
-msgstr "Close"
-
-#: TFMINGREDIENTS.BTPRINT.CAPTION
-msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
-msgid "Print..."
-msgstr "Print..."
-
-#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
-msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
-msgid "Ingredients"
-msgstr "Ingredients"
-
-#: TFMMAIN.BTCLEAR.CAPTION
-msgctxt "TFMMAIN.BTCLEAR.CAPTION"
-msgid "Clear"
-msgstr "Clear"
-
-#: TFMMAIN.BTDOWN.CAPTION
-msgctxt "TFMMAIN.BTDOWN.CAPTION"
-msgid "Down"
-msgstr "Down"
-
-#: TFMMAIN.BTEDIT.CAPTION
-msgid "Edit..."
-msgstr "Edit..."
-
-#: TFMMAIN.BTINGREDIENTS.CAPTION
-msgid "Ingredients List..."
-msgstr "Ingredients List..."
-
-#: TFMMAIN.BTNEW.CAPTION
-msgid "New..."
-msgstr "New..."
-
-#: TFMMAIN.BTPRINT.CAPTION
-msgctxt "TFMMAIN.BTPRINT.CAPTION"
-msgid "Print..."
-msgstr "Print..."
-
-#: TFMMAIN.BTREMOVE.CAPTION
-msgctxt "TFMMAIN.BTREMOVE.CAPTION"
-msgid "Remove"
-msgstr "Remove"
-
-#: TFMMAIN.BTUP.CAPTION
-msgctxt "TFMMAIN.BTUP.CAPTION"
-msgid "Up"
-msgstr "Up"
-
-#: TFMMAIN.FMMAIN.CAPTION
-msgctxt "TFMMAIN.FMMAIN.CAPTION"
-msgid "fmMain"
-msgstr "Main"
-
-#: TFMMAIN.GBMENU.CAPTION
-msgctxt "TFMMAIN.GBMENU.CAPTION"
-msgid "Menu"
-msgstr "Menu"
-
-#: TFMMEAL.ACADD.CAPTION
-msgctxt "TFMMEAL.ACADD.CAPTION"
-msgid "Add"
-msgstr "Add"
-
-#: TFMMEAL.ACADDANDCLOSE.CAPTION
-msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
-msgid "Add and Close"
-msgstr "Add and Close"
-
-#: TFMMEAL.ACCANCEL.CAPTION
-msgctxt "TFMMEAL.ACCANCEL.CAPTION"
-msgid "Cancel"
-msgstr "Cancel"
-
-#: TFMMEAL.ACCLOSE.CAPTION
-msgctxt "TFMMEAL.ACCLOSE.CAPTION"
-msgid "Close"
-msgstr "Close"
-
-#: TFMMEAL.ACOK.CAPTION
-msgctxt "TFMMEAL.ACOK.CAPTION"
-msgid "OK"
-msgstr "OK"
-
-#: TFMMEAL.BTACTION.CAPTION
-msgid "Action"
-msgstr ""
-
-#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
-msgid "Action and Close"
-msgstr ""
-
-#: TFMMEAL.BTADDDISH.CAPTION
-msgctxt "TFMMEAL.BTADDDISH.CAPTION"
-msgid "Add"
-msgstr "Add"
-
-#: TFMMEAL.BTCLEAR.CAPTION
-msgctxt "TFMMEAL.BTCLEAR.CAPTION"
-msgid "Clear"
-msgstr "Clear"
-
-#: TFMMEAL.BTCLOSE.CAPTION
-msgctxt "TFMMEAL.BTCLOSE.CAPTION"
-msgid "Close"
-msgstr "Close"
-
-#: TFMMEAL.BTDOWN.CAPTION
-msgctxt "TFMMEAL.BTDOWN.CAPTION"
-msgid "Down"
-msgstr "Down"
-
-#: TFMMEAL.BTREMOVE.CAPTION
-msgctxt "TFMMEAL.BTREMOVE.CAPTION"
-msgid "Remove"
-msgstr "Remove"
-
-#: TFMMEAL.BTUP.CAPTION
-msgctxt "TFMMEAL.BTUP.CAPTION"
-msgid "Up"
-msgstr "Up"
-
-#: TFMMEAL.DEDATE.CANCELCAPTION
-#| msgid "Cancelar"
-msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
-msgid "Cancel"
-msgstr "Cancel"
-
-#: TFMMEAL.DEDATE.DIALOGTITLE
-#| msgid "Escolha a data"
-msgid "Choose the date"
-msgstr "Choose the Date"
-
-#: TFMMEAL.DEDATE.OKCAPTION
-msgctxt "TFMMEAL.DEDATE.OKCAPTION"
-msgid "OK"
-msgstr "OK"
-
-#: TFMMEAL.FMMEAL.CAPTION
-msgctxt "TFMMEAL.FMMEAL.CAPTION"
-msgid "Meal"
-msgstr "Meal"
-
-#: TFMMEAL.GBMEAL.CAPTION
-msgctxt "TFMMEAL.GBMEAL.CAPTION"
-msgid "Meal"
-msgstr "Meal"
-
-#: TFMMEAL.LBDATE.CAPTION
-msgid "Date:"
-msgstr "Date:"
-
-#: TFMMEAL.LBDISH.CAPTION
-msgid "Dish:"
-msgstr "Dish:"
-
-#: TFMMEAL.LBLMEAL.CAPTION
-msgid "Meal:"
-msgstr "Meal:"
-
-#: TFMMEAL.LBTYPE.CAPTION
-msgid "Dish Type:"
-msgstr "Dish Type:"
-
-#: u_consts.sdate
-#| msgid "Data"
-msgid "Date"
-msgstr "Date"
-
-#: u_consts.sdishes
-#| msgid "Pratos"
-msgid "Dishes"
-msgstr "Dishes"
-
-#: u_consts.serror
-msgid "Error!!!"
-msgstr "Error!!!"
-
+msgid ""
+msgstr ""
+"Content-Type: text/plain; charset=UTF-8\n"
+"Project-Id-Version: Gotosso Meal Planner\n"
+"POT-Creation-Date: \n"
+"PO-Revision-Date: \n"
+"Last-Translator: João Marcelo S. Vaz <jm...@gm...>\n"
+"Language-Team: João Marcelo S. Vaz\n"
+"MIME-Version: 1.0\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-Language: English\n"
+"X-Poedit-Country: UNITED STATES\n"
+
+#: TFMINGREDIENTS.BTCLOSE.CAPTION
+msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
+msgid "Close"
+msgstr "Close"
+
+#: TFMINGREDIENTS.BTPRINT.CAPTION
+msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
+msgid "Print..."
+msgstr "Print..."
+
+#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
+msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
+msgid "Ingredients"
+msgstr "Ingredients"
+
+#: TFMMAIN.BTCLEAR.CAPTION
+msgctxt "TFMMAIN.BTCLEAR.CAPTION"
+msgid "Clear"
+msgstr "Clear"
+
+#: TFMMAIN.BTDOWN.CAPTION
+msgctxt "TFMMAIN.BTDOWN.CAPTION"
+msgid "Down"
+msgstr "Down"
+
+#: TFMMAIN.BTEDIT.CAPTION
+msgid "Edit..."
+msgstr "Edit..."
+
+#: TFMMAIN.BTINGREDIENTS.CAPTION
+msgid "Ingredients List..."
+msgstr "Ingredients List..."
+
+#: TFMMAIN.BTNEW.CAPTION
+msgid "New..."
+msgstr "New..."
+
+#: TFMMAIN.BTPRINT.CAPTION
+msgctxt "TFMMAIN.BTPRINT.CAPTION"
+msgid "Print..."
+msgstr "Print..."
+
+#: TFMMAIN.BTREMOVE.CAPTION
+msgctxt "TFMMAIN.BTREMOVE.CAPTION"
+msgid "Remove"
+msgstr "Remove"
+
+#: TFMMAIN.BTUP.CAPTION
+msgctxt "TFMMAIN.BTUP.CAPTION"
+msgid "Up"
+msgstr "Up"
+
+#: TFMMAIN.FMMAIN.CAPTION
+msgctxt "TFMMAIN.FMMAIN.CAPTION"
+msgid "fmMain"
+msgstr "Main"
+
+#: TFMMAIN.GBMENU.CAPTION
+msgctxt "TFMMAIN.GBMENU.CAPTION"
+msgid "Menu"
+msgstr "Menu"
+
+#: TFMMEAL.ACADD.CAPTION
+msgctxt "TFMMEAL.ACADD.CAPTION"
+msgid "Add"
+msgstr "Add"
+
+#: TFMMEAL.ACADDANDCLOSE.CAPTION
+msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
+msgid "Add and Close"
+msgstr "Add and Close"
+
+#: TFMMEAL.ACCANCEL.CAPTION
+msgctxt "TFMMEAL.ACCANCEL.CAPTION"
+msgid "Cancel"
+msgstr "Cancel"
+
+#: TFMMEAL.ACCLOSE.CAPTION
+msgctxt "TFMMEAL.ACCLOSE.CAPTION"
+msgid "Close"
+msgstr "Close"
+
+#: TFMMEAL.ACOK.CAPTION
+msgctxt "TFMMEAL.ACOK.CAPTION"
+msgid "OK"
+msgstr "OK"
+
+#: TFMMEAL.BTACTION.CAPTION
+msgid "Action"
+msgstr ""
+
+#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
+msgid "Action and Close"
+msgstr ""
+
+#: TFMMEAL.BTADDDISH.CAPTION
+msgctxt "TFMMEAL.BTADDDISH.CAPTION"
+msgid "Add"
+msgstr "Add"
+
+#: TFMMEAL.BTCLEAR.CAPTION
+msgctxt "TFMMEAL.BTCLEAR.CAPTION"
+msgid "Clear"
+msgstr "Clear"
+
+#: TFMMEAL.BTCLOSE.CAPTION
+msgctxt "TFMMEAL.BTCLOSE.CAPTION"
+msgid "Close"
+msgstr "Close"
+
+#: TFMMEAL.BTDOWN.CAPTION
+msgctxt "TFMMEAL.BTDOWN.CAPTION"
+msgid "Down"
+msgstr "Down"
+
+#: TFMMEAL.BTREMOVE.CAPTION
+msgctxt "TFMMEAL.BTREMOVE.CAPTION"
+msgid "Remove"
+msgstr "Remove"
+
+#: TFMMEAL.BTUP.CAPTION
+msgctxt "TFMMEAL.BTUP.CAPTION"
+msgid "Up"
+msgstr "Up"
+
+#: TFMMEAL.DEDATE.CANCELCAPTION
+#| msgid "Cancelar"
+msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
+msgid "Cancel"
+msgstr "Cancel"
+
+#: TFMMEAL.DEDATE.DIALOGTITLE
+#| msgid "Escolha a data"
+msgid "Choose the date"
+msgstr "Choose the Date"
+
+#: TFMMEAL.DEDATE.OKCAPTION
+msgctxt "TFMMEAL.DEDATE.OKCAPTION"
+msgid "OK"
+msgstr "OK"
+
+#: TFMMEAL.FMMEAL.CAPTION
+msgctxt "TFMMEAL.FMMEAL.CAPTION"
+msgid "Meal"
+msgstr "Meal"
+
+#: TFMMEAL.GBMEAL.CAPTION
+msgctxt "TFMMEAL.GBMEAL.CAPTION"
+msgid "Meal"
+msgstr "Meal"
+
+#: TFMMEAL.LBDATE.CAPTION
+msgid "Date:"
+msgstr "Date:"
+
+#: TFMMEAL.LBDISH.CAPTION
+msgid "Dish:"
+msgstr "Dish:"
+
+#: TFMMEAL.LBLMEAL.CAPTION
+msgid "Meal:"
+msgstr "Meal:"
+
+#: TFMMEAL.LBTYPE.CAPTION
+msgid "Dish Type:"
+msgstr "Dish Type:"
+
+#: u_consts.sdate
+#| msgid "Data"
+msgid "Date"
+msgstr "Date"
+
+#: u_consts.sdishes
+#| msgid "Pratos"
+msgid "Dishes"
+msgstr "Dishes"
+
+#: u_consts.serror
+msgid "Error!!!"
+msgstr "Error!!!"
+
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2010-08-23 03:55:24 UTC (rev 22)
+++ trunk/lang/gotisso.po 2010-08-23 04:22:55 UTC (rev 23)
@@ -1,179 +1,179 @@
-msgid ""
-msgstr "Content-Type: text/plain; charset=UTF-8"
-
-#: TFMINGREDIENTS.BTCLOSE.CAPTION
-msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
-msgid "Close"
-msgstr ""
-
-#: TFMINGREDIENTS.BTPRINT.CAPTION
-msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
-msgid "Print..."
-msgstr ""
-
-#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
-msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
-msgid "Ingredients"
-msgstr ""
-
-#: TFMMAIN.BTCLEAR.CAPTION
-msgctxt "TFMMAIN.BTCLEAR.CAPTION"
-msgid "Clear"
-msgstr ""
-
-#: TFMMAIN.BTDOWN.CAPTION
-msgctxt "TFMMAIN.BTDOWN.CAPTION"
-msgid "Down"
-msgstr ""
-
-#: TFMMAIN.BTEDIT.CAPTION
-msgid "Edit..."
-msgstr ""
-
-#: TFMMAIN.BTINGREDIENTS.CAPTION
-msgid "Ingredients List..."
-msgstr ""
-
-#: TFMMAIN.BTNEW.CAPTION
-msgid "New..."
-msgstr ""
-
-#: TFMMAIN.BTPRINT.CAPTION
-msgctxt "TFMMAIN.BTPRINT.CAPTION"
-msgid "Print..."
-msgstr ""
-
-#: TFMMAIN.BTREMOVE.CAPTION
-msgctxt "TFMMAIN.BTREMOVE.CAPTION"
-msgid "Remove"
-msgstr ""
-
-#: TFMMAIN.BTUP.CAPTION
-msgctxt "TFMMAIN.BTUP.CAPTION"
-msgid "Up"
-msgstr ""
-
-#: TFMMAIN.FMMAIN.CAPTION
-msgctxt "TFMMAIN.FMMAIN.CAPTION"
-msgid "fmMain"
-msgstr ""
-
-#: TFMMAIN.GBMENU.CAPTION
-msgid "Menu"
-msgstr ""
-
-#: TFMMEAL.ACADD.CAPTION
-msgctxt "TFMMEAL.ACADD.CAPTION"
-msgid "Add"
-msgstr ""
-
-#: TFMMEAL.ACADDANDCLOSE.CAPTION
-msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
-msgid "Add and Close"
-msgstr ""
-
-#: TFMMEAL.ACCANCEL.CAPTION
-msgctxt "TFMMEAL.ACCANCEL.CAPTION"
-msgid "Cancel"
-msgstr ""
-
-#: TFMMEAL.ACCLOSE.CAPTION
-msgctxt "TFMMEAL.ACCLOSE.CAPTION"
-msgid "Close"
-msgstr ""
-
-#: TFMMEAL.ACOK.CAPTION
-msgctxt "TFMMEAL.ACOK.CAPTION"
-msgid "OK"
-msgstr ""
-
-#: TFMMEAL.BTACTION.CAPTION
-msgid "Action"
-msgstr ""
-
-#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
-msgid "Action and Close"
-msgstr ""
-
-#: TFMMEAL.BTADDDISH.CAPTION
-msgctxt "TFMMEAL.BTADDDISH.CAPTION"
-msgid "Add"
-msgstr ""
-
-#: TFMMEAL.BTCLEAR.CAPTION
-msgctxt "TFMMEAL.BTCLEAR.CAPTION"
-msgid "Clear"
-msgstr ""
-
-#: TFMMEAL.BTCLOSE.CAPTION
-msgctxt "TFMMEAL.BTCLOSE.CAPTION"
-msgid "Close"
-msgstr ""
-
-#: TFMMEAL.BTDOWN.CAPTION
-msgctxt "TFMMEAL.BTDOWN.CAPTION"
-msgid "Down"
-msgstr ""
-
-#: TFMMEAL.BTREMOVE.CAPTION
-msgctxt "TFMMEAL.BTREMOVE.CAPTION"
-msgid "Remove"
-msgstr ""
-
-#: TFMMEAL.BTUP.CAPTION
-msgctxt "TFMMEAL.BTUP.CAPTION"
-msgid "Up"
-msgstr ""
-
-#: TFMMEAL.DEDATE.CANCELCAPTION
-msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
-msgid "Cancel"
-msgstr ""
-
-#: TFMMEAL.DEDATE.DIALOGTITLE
-msgid "Choose the date"
-msgstr ""
-
-#: TFMMEAL.DEDATE.OKCAPTION
-msgctxt "TFMMEAL.DEDATE.OKCAPTION"
-msgid "OK"
-msgstr ""
-
-#: TFMMEAL.FMMEAL.CAPTION
-msgctxt "TFMMEAL.FMMEAL.CAPTION"
-msgid "Meal"
-msgstr ""
-
-#: TFMMEAL.GBMEAL.CAPTION
-msgctxt "TFMMEAL.GBMEAL.CAPTION"
-msgid "Meal"
-msgstr ""
-
-#: TFMMEAL.LBDATE.CAPTION
-msgid "Date:"
-msgstr ""
-
-#: TFMMEAL.LBDISH.CAPTION
-msgid "Dish:"
-msgstr ""
-
-#: TFMMEAL.LBLMEAL.CAPTION
-msgid "Meal:"
-msgstr ""
-
-#: TFMMEAL.LBTYPE.CAPTION
-msgid "Dish Type:"
-msgstr ""
-
-#: u_consts.sdate
-msgid "Date"
-msgstr ""
-
-#: u_consts.sdishes
-msgid "Dishes"
-msgstr ""
-
-#: u_consts.serror
-msgid "Error!!!"
-msgstr ""
-
+msgid ""
+msgstr "Content-Type: text/plain; charset=UTF-8"
+
+#: TFMINGREDIENTS.BTCLOSE.CAPTION
+msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
+msgid "Close"
+msgstr ""
+
+#: TFMINGREDIENTS.BTPRINT.CAPTION
+msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
+msgid "Print..."
+msgstr ""
+
+#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
+msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
+msgid "Ingredients"
+msgstr ""
+
+#: TFMMAIN.BTCLEAR.CAPTION
+msgctxt "TFMMAIN.BTCLEAR.CAPTION"
+msgid "Clear"
+msgstr ""
+
+#: TFMMAIN.BTDOWN.CAPTION
+msgctxt "TFMMAIN.BTDOWN.CAPTION"
+msgid "Down"
+msgstr ""
+
+#: TFMMAIN.BTEDIT.CAPTION
+msgid "Edit..."
+msgstr ""
+
+#: TFMMAIN.BTINGREDIENTS.CAPTION
+msgid "Ingredients List..."
+msgstr ""
+
+#: TFMMAIN.BTNEW.CAPTION
+msgid "New..."
+msgstr ""
+
+#: TFMMAIN.BTPRINT.CAPTION
+msgctxt "TFMMAIN.BTPRINT.CAPTION"
+msgid "Print..."
+msgstr ""
+
+#: TFMMAIN.BTREMOVE.CAPTION
+msgctxt "TFMMAIN.BTREMOVE.CAPTION"
+msgid "Remove"
+msgstr ""
+
+#: TFMMAIN.BTUP.CAPTION
+msgctxt "TFMMAIN.BTUP.CAPTION"
+msgid "Up"
+msgstr ""
+
+#: TFMMAIN.FMMAIN.CAPTION
+msgctxt "TFMMAIN.FMMAIN.CAPTION"
+msgid "fmMain"
+msgstr ""
+
+#: TFMMAIN.GBMENU.CAPTION
+msgid "Menu"
+msgstr ""
+
+#: TFMMEAL.ACADD.CAPTION
+msgctxt "TFMMEAL.ACADD.CAPTION"
+msgid "Add"
+msgstr ""
+
+#: TFMMEAL.ACADDANDCLOSE.CAPTION
+msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
+msgid "Add and Close"
+msgstr ""
+
+#: TFMMEAL.ACCANCEL.CAPTION
+msgctxt "TFMMEAL.ACCANCEL.CAPTION"
+msgid "Cancel"
+msgstr ""
+
+#: TFMMEAL.ACCLOSE.CAPTION
+msgctxt "TFMMEAL.ACCLOSE.CAPTION"
+msgid "Close"
+msgstr ""
+
+#: TFMMEAL.ACOK.CAPTION
+msgctxt "TFMMEAL.ACOK.CAPTION"
+msgid "OK"
+msgstr ""
+
+#: TFMMEAL.BTACTION.CAPTION
+msgid "Action"
+msgstr ""
+
+#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
+msgid "Action and Close"
+msgstr ""
+
+#: TFMMEAL.BTADDDISH.CAPTION
+msgctxt "TFMMEAL.BTADDDISH.CAPTION"
+msgid "Add"
+msgstr ""
+
+#: TFMMEAL.BTCLEAR.CAPTION
+msgctxt "TFMMEAL.BTCLEAR.CAPTION"
+msgid "Clear"
+msgstr ""
+
+#: TFMMEAL.BTCLOSE.CAPTION
+msgctxt "TFMMEAL.BTCLOSE.CAPTION"
+msgid "Close"
+msgstr ""
+
+#: TFMMEAL.BTDOWN.CAPTION
+msgctxt "TFMMEAL.BTDOWN.CAPTION"
+msgid "Down"
+msgstr ""
+
+#: TFMMEAL.BTREMOVE.CAPTION
+msgctxt "TFMMEAL.BTREMOVE.CAPTION"
+msgid "Remove"
+msgstr ""
+
+#: TFMMEAL.BTUP.CAPTION
+msgctxt "TFMMEAL.BTUP.CAPTION"
+msgid "Up"
+msgstr ""
+
+#: TFMMEAL.DEDATE.CANCELCAPTION
+msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
+msgid "Cancel"
+msgstr ""
+
+#: TFMMEAL.DEDATE.DIALOGTITLE
+msgid "Choose the date"
+msgstr ""
+
+#: TFMMEAL.DEDATE.OKCAPTION
+msgctxt "TFMMEAL.DEDATE.OKCAPTION"
+msgid "OK"
+msgstr ""
+
+#: TFMMEAL.FMMEAL.CAPTION
+msgctxt "TFMMEAL.FMMEAL.CAPTION"
+msgid "Meal"
+msgstr ""
+
+#: TFMMEAL.GBMEAL.CAPTION
+msgctxt "TFMMEAL.GBMEAL.CAPTION"
+msgid "Meal"
+msgstr ""
+
+#: TFMMEAL.LBDATE.CAPTION
+msgid "Date:"
+msgstr ""
+
+#: TFMMEAL.LBDISH.CAPTION
+msgid "Dish:"
+msgstr ""
+
+#: TFMMEAL.LBLMEAL.CAPTION
+msgid "Meal:"
+msgstr ""
+
+#: TFMMEAL.LBTYPE.CAPTION
+msgid "Dish Type:"
+msgstr ""
+
+#: u_consts.sdate
+msgid "Date"
+msgstr ""
+
+#: u_consts.sdishes
+msgid "Dishes"
+msgstr ""
+
+#: u_consts.serror
+msgid "Error!!!"
+msgstr ""
+
Modified: trunk/lang/gotisso.pt_BR.po
===================================================================
--- trunk/lang/gotisso.pt_BR.po 2010-08-23 03:55:24 UTC (rev 22)
+++ trunk/lang/gotisso.pt_BR.po 2010-08-23 04:22:55 UTC (rev 23)
@@ -1,213 +1,213 @@
-msgid ""
-msgstr ""
-"Content-Type: text/plain; charset=UTF-8\n"
-"Project-Id-Version: Gotisso\n"
-"POT-Creation-Date: \n"
-"PO-Revision-Date: \n"
-"Last-Translator: João Marcelo S. Vaz <jm...@gm...>\n"
-"Language-Team: João Marcelo S. Vaz\n"
-"MIME-Version: 1.0\n"
-"Content-Transfer-Encoding: 8bit\n"
-"X-Poedit-Language: Portuguese\n"
-"X-Poedit-Country: BRAZIL\n"
-"X-Poedit-SourceCharset: utf-8\n"
-
-#: TFMINGREDIENTS.BTCLOSE.CAPTION
-#| msgid "Fechar"
-msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
-msgid "Close"
-msgstr "Fechar"
-
-#: TFMINGREDIENTS.BTPRINT.CAPTION
-#| msgid "Imprimir..."
-msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
-msgid "Print..."
-msgstr "Imprimir..."
-
-#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
-msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
-msgid "Ingredients"
-msgstr "Ingredientes"
-
-#: TFMMAIN.BTCLEAR.CAPTION
-#| msgid "Limpar"
-msgctxt "TFMMAIN.BTCLEAR.CAPTION"
-msgid "Clear"
-msgstr "Limpar"
-
-#: TFMMAIN.BTDOWN.CAPTION
-msgctxt "TFMMAIN.BTDOWN.CAPTION"
-msgid "Down"
-msgstr "Para baixo"
-
-#: TFMMAIN.BTEDIT.CAPTION
-msgid "Edit..."
-msgstr "Editar..."
-
-#: TFMMAIN.BTINGREDIENTS.CAPTION
-#| msgid "Lista de Ingredientes..."
-msgid "Ingredients List..."
-msgstr "Lista de Ingredientes..."
-
-#: TFMMAIN.BTNEW.CAPTION
-#| msgid "Nova..."
-msgid "New..."
-msgstr "Nova..."
-
-#: TFMMAIN.BTPRINT.CAPTION
-#| msgid "Imprimir..."
-msgctxt "TFMMAIN.BTPRINT.CAPTION"
-msgid "Print..."
-msgstr "Imprimir..."
-
-#: TFMMAIN.BTREMOVE.CAPTION
-msgctxt "TFMMAIN.BTREMOVE.CAPTION"
-msgid "Remove"
-msgstr "Remover"
-
-#: TFMMAIN.BTUP.CAPTION
-msgctxt "TFMMAIN.BTUP.CAPTION"
-msgid "Up"
-msgstr "Para cima"
-
-#: TFMMAIN.FMMAIN.CAPTION
-msgctxt "TFMMAIN.FMMAIN.CAPTION"
-msgid "fmMain"
-msgstr "Principal"
-
-#: TFMMAIN.GBMENU.CAPTION
-#| msgid "Cardápio"
-msgctxt "TFMMAIN.GBMENU.CAPTION"
-msgid "Menu"
-msgstr "Cardápio"
-
-#: TFMMEAL.ACADD.CAPTION
-msgctxt "TFMMEAL.ACADD.CAPTION"
-msgid "Add"
-msgstr "Adicionar"
-
-#: TFMMEAL.ACADDANDCLOSE.CAPTION
-msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
-msgid "Add and Close"
-msgstr "Adicionar e Fechar"
-
-#: TFMMEAL.ACCANCEL.CAPTION
-msgctxt "TFMMEAL.ACCANCEL.CAPTION"
-msgid "Cancel"
-msgstr "Cancelar"
-
-#: TFMMEAL.ACCLOSE.CAPTION
-msgctxt "TFMMEAL.ACCLOSE.CAPTION"
-msgid "Close"
-msgstr "Fechar"
-
-#: TFMMEAL.ACOK.CAPTION
-msgctxt "TFMMEAL.ACOK.CAPTION"
-msgid "OK"
-msgstr "OK"
-
-#: TFMMEAL.BTACTION.CAPTION
-msgid "Action"
-msgstr ""
-
-#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
-msgid "Action and Close"
-msgstr ""
-
-#: TFMMEAL.BTADDDISH.CAPTION
-#| msgid "Adicionar"
-msgctxt "TFMMEAL.BTADDDISH.CAPTION"
-msgid "Add"
-msgstr "Adicionar"
-
-#: TFMMEAL.BTCLEAR.CAPTION
-#| msgid "Limpar"
-msgctxt "TFMMEAL.BTCLEAR.CAPTION"
-msgid "Clear"
-msgstr "Limpar"
-
-#: TFMMEAL.BTCLOSE.CAPTION
-#| msgid "Fechar"
-msgctxt "TFMMEAL.BTCLOSE.CAPTION"
-msgid "Close"
-msgstr "Fechar"
-
-#: TFMMEAL.BTDOWN.CAPTION
-#| msgid "Abaixo"
-msgctxt "TFMMEAL.BTDOWN.CAPTION"
-msgid "Down"
-msgstr "Para baixo"
-
-#: TFMMEAL.BTREMOVE.CAPTION
-#| msgid "Remover"
-msgctxt "TFMMEAL.BTREMOVE.CAPTION"
-msgid "Remove"
-msgstr "Remover"
-
-#: TFMMEAL.BTUP.CAPTION
-#| msgid "Acima"
-msgctxt "TFMMEAL.BTUP.CAPTION"
-msgid "Up"
-msgstr "Para cima"
-
-#: TFMMEAL.DEDATE.CANCELCAPTION
-#| msgid "Cancelar"
-msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
-msgid "Cancel"
-msgstr "Cancelar"
-
-#: TFMMEAL.DEDATE.DIALOGTITLE
-#| msgid "Escolha a data"
-msgid "Choose the date"
-msgstr "Escolha a data"
-
-#: TFMMEAL.DEDATE.OKCAPTION
-msgctxt "TFMMEAL.DEDATE.OKCAPTION"
-msgid "OK"
-msgstr "OK"
-
-#: TFMMEAL.FMMEAL.CAPTION
-msgctxt "TFMMEAL.FMMEAL.CAPTION"
-msgid "Meal"
-msgstr "Refeição"
-
-#: TFMMEAL.GBMEAL.CAPTION
-#| msgid "Refeição"
-msgctxt "TFMMEAL.GBMEAL.CAPTION"
-msgid "Meal"
-msgstr "Refeição"
-
-#: TFMMEAL.LBDATE.CAPTION
-#| msgid "Data:"
-msgid "Date:"
-msgstr "Data:"
-
-#: TFMMEAL.LBDISH.CAPTION
-#| msgid "Prato:"
-msgid "Dish:"
-msgstr "Prato:"
-
-#: TFMMEAL.LBLMEAL.CAPTION
-#| msgid "Refeição:"
-msgid "Meal:"
-msgstr "Refeição:"
-
-#: TFMMEAL.LBTYPE.CAPTION
-#| msgid "Tipo:"
-msgid "Dish Type:"
-msgstr "Tipo:"
-
-#: u_consts.sdate
-#| msgid "Data"
-msgid "Date"
-msgstr "Data"
-
-#: u_consts.sdishes
-#| msgid "Pratos"
-msgid "Dishes"
-msgstr "Pratos"
-
-#: u_consts.serror
-msgid "Error!!!"
-msgstr "Erro!!!"
-
+msgid ""
+msgstr ""
+"Content-Type: text/plain; charset=UTF-8\n"
+"Project-Id-Version: Gotisso\n"
+"POT-Creation-Date: \n"
+"PO-Revision-Date: \n"
+"Last-Translator: João Marcelo S. Vaz <jm...@gm...>\n"
+"Language-Team: João Marcelo S. Vaz\n"
+"MIME-Version: 1.0\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-Language: Portuguese\n"
+"X-Poedit-Country: BRAZIL\n"
+"X-Poedit-SourceCharset: utf-8\n"
+
+#: TFMINGREDIENTS.BTCLOSE.CAPTION
+#| msgid "Fechar"
+msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
+msgid "Close"
+msgstr "Fechar"
+
+#: TFMINGREDIENTS.BTPRINT.CAPTION
+#| msgid "Imprimir..."
+msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
+msgid "Print..."
+msgstr "Imprimir..."
+
+#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
+msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
+msgid "Ingredients"
+msgstr "Ingredientes"
+
+#: TFMMAIN.BTCLEAR.CAPTION
+#| msgid "Limpar"
+msgctxt "TFMMAIN.BTCLEAR.CAPTION"
+msgid "Clear"
+msgstr "Limpar"
+
+#: TFMMAIN.BTDOWN.CAPTION
+msgctxt "TFMMAIN.BTDOWN.CAPTION"
+msgid "Down"
+msgstr "Para baixo"
+
+#: TFMMAIN.BTEDIT.CAPTION
+msgid "Edit..."
+msgstr "Editar..."
+
+#: TFMMAIN.BTINGREDIENTS.CAPTION
+#| msgid "Lista de Ingredientes..."
+msgid "Ingredients List..."
+msgstr "Lista de Ingredientes..."
+
+#: TFMMAIN.BTNEW.CAPTION
+#| msgid "Nova..."
+msgid "New..."
+msgstr "Nova..."
+
+#: TFMMAIN.BTPRINT.CAPTION
+#| msgid "Imprimir..."
+msgctxt "TFMMAIN.BTPRINT.CAPTION"
+msgid "Print..."
+msgstr "Imprimir..."
+
+#: TFMMAIN.BTREMOVE.CAPTION
+msgctxt "TFMMAIN.BTREMOVE.CAPTION"
+msgid "Remove"
+msgstr "Remover"
+
+#: TFMMAIN.BTUP.CAPTION
+msgctxt "TFMMAIN.BTUP.CAPTION"
+msgid "Up"
+msgstr "Para cima"
+
+#: TFMMAIN.FMMAIN.CAPTION
+msgctxt "TFMMAIN.FMMAIN.CAPTION"
+msgid "fmMain"
+msgstr "Principal"
+
+#: TFMMAIN.GBMENU.CAPTION
+#| msgid "Cardápio"
+msgctxt "TFMMAIN.GBMENU.CAPTION"
+msgid "Menu"
+msgstr "Cardápio"
+
+#: TFMMEAL.ACADD.CAPTION
+msgctxt "TFMMEAL.ACADD.CAPTION"
+msgid "Add"
+msgstr "Adicionar"
+
+#: TFMMEAL.ACADDANDCLOSE.CAPTION
+msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
+msgid "Add and Close"
+msgstr "Adicionar e Fechar"
+
+#: TFMMEAL.ACCANCEL.CAPTION
+msgctxt "TFMMEAL.ACCANCEL.CAPTION"
+msgid "Cancel"
+msgstr "Cancelar"
+
+#: TFMMEAL.ACCLOSE.CAPTION
+msgctxt "TFMMEAL.ACCLOSE.CAPTION"
+msgid "Close"
+msgstr "Fechar"
+
+#: TFMMEAL.ACOK.CAPTION
+msgctxt "TFMMEAL.ACOK.CAPTION"
+msgid "OK"
+msgstr "OK"
+
+#: TFMMEAL.BTACTION.CAPTION
+msgid "Action"
+msgstr ""
+
+#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
+msgid "Action and Close"
+msgstr ""
+
+#: TFMMEAL.BTADDDISH.CAPTION
+#| msgid "Adicionar"
+msgctxt "TFMMEAL.BTADDDISH.CAPTION"
+msgid "Add"
+msgstr "Adicionar"
+
+#: TFMMEAL.BTCLEAR.CAPTION
+#| msgid "Limpar"
+msgctxt "TFMMEAL.BTCLEAR.CAPTION"
+msgid "Clear"
+msgstr "Limpar"
+
+#: TFMMEAL.BTCLOSE.CAPTION
+#| msgid "Fechar"
+msgctxt "TFMMEAL.BTCLOSE.CAPTION"
+msgid "Close"
+msgstr "Fechar"
+
+#: TFMMEAL.BTDOWN.CAPTION
+#| msgid "Abaixo"
+msgctxt "TFMMEAL.BTDOWN.CAPTION"
+msgid "Down"
+msgstr "Para baixo"
+
+#: TFMMEAL.BTREMOVE.CAPTION
+#| msgid "Remover"
+msgctxt "TFMMEAL.BTREMOVE.CAPTION"
+msgid "Remove"
+msgstr "Remover"
+
+#: TFMMEAL.BTUP.CAPTION
+#| msgid "Acima"
+msgctxt "TFMMEAL.BTUP.CAPTION"
+msgid "Up"
+msgstr "Para cima"
+
+#: TFMMEAL.DEDATE.CANCELCAPTION
+#| msgid "Cancelar"
+msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
+msgid "Cancel"
+msgstr "Cancelar"
+
+#: TFMMEAL.DEDATE.DIALOGTITLE
+#| msgid "Escolha a data"
+msgid "Choose the date"
+msgstr "Escolha a data"
+
+#: TFMMEAL.DEDATE.OKCAPTION
+msgctxt "TFMMEAL.DEDATE.OKCAPTION"
+msgid "OK"
+msgstr "OK"
+
+#: TFMMEAL.FMMEAL.CAPTION
+msgctxt "TFMMEAL.FMMEAL.CAPTION"
+msgid "Meal"
+msgstr "Refeição"
+
+#: TFMMEAL.GBMEAL.CAPTION
+#| msgid "Refeição"
+msgctxt "TFMMEAL.GBMEAL.CAPTION"
+msgid "Meal"
+msgstr "Refeição"
+
+#: TFMMEAL.LBDATE.CAPTION
+#| msgid "Data:"
+msgid "Date:"
+msgstr "Data:"
+
+#: TFMMEAL.LBDISH.CAPTION
+#| msgid "Prato:"
+msgid "Dish:"
+msgstr "Prato:"
+
+#: TFMMEAL.LBLMEAL.CAPTION
+#| msgid "Refeição:"
+msgid "Meal:"
+msgstr "Refeição:"
+
+#: TFMMEAL.LBTYPE.CAPTION
+#| msgid "Tipo:"
+msgid "Dish Type:"
+msgstr "Tipo:"
+
+#: u_consts.sdate
+#| msgid "Data"
+msgid "Date"
+msgstr "Data"
+
+#: u_consts.sdishes
+#| msgid "Pratos"
+msgid "Dishes"
+msgstr "Pratos"
+
+#: u_consts.serror
+msgid "Error!!!"
+msgstr "Erro!!!"
+
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2010-08-23 03:55:31
|
Revision: 22
http://gotisso.svn.sourceforge.net/gotisso/?rev=22&view=rev
Author: jmvaz
Date: 2010-08-23 03:55:24 +0000 (Mon, 23 Aug 2010)
Log Message:
-----------
the menu grid is Date ordered and minor changes
Modified Paths:
--------------
trunk/gotisso.lpr
trunk/u_main.lfm
trunk/u_main.pas
trunk/u_meal.lfm
trunk/u_meal.pas
Modified: trunk/gotisso.lpr
===================================================================
--- trunk/gotisso.lpr 2010-08-23 02:22:51 UTC (rev 21)
+++ trunk/gotisso.lpr 2010-08-23 03:55:24 UTC (rev 22)
@@ -32,8 +32,6 @@
{ you can add units after this },
Printer4Lazarus, u_main, u_meal, u_ingredients, u_classes, u_consts;
-//{$IFDEF WINDOWS}{$R gotisso.rc}{$ENDIF}
-
{$R *.res}
begin
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2010-08-23 02:22:51 UTC (rev 21)
+++ trunk/u_main.lfm 2010-08-23 03:55:24 UTC (rev 22)
@@ -34,7 +34,12 @@
TabOrder = 0
TitleStyle = tsStandard
OnClick = sgMenuClick
+ OnCompareCells = sgMenuCompareCells
OnDblClick = sgMenuDblClick
+ ColWidths = (
+ 136
+ 247
+ )
end
object btNew: TButton
Left = 686
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2010-08-23 02:22:51 UTC (rev 21)
+++ trunk/u_main.pas 2010-08-23 03:55:24 UTC (rev 22)
@@ -56,6 +56,8 @@
procedure FormDestroy(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure sgMenuClick(Sender: TObject);
+ procedure sgMenuCompareCells(Sender: TObject; ACol, ARow, BCol,
+ BRow: Integer; var Result: integer);
procedure sgMenuDblClick(Sender: TObject);
private
{ private declarations }
@@ -118,6 +120,12 @@
UpdateMenu;
end;
+procedure TfmMain.sgMenuCompareCells(Sender: TObject; ACol, ARow, BCol,
+ BRow: Integer; var Result: integer);
+begin
+ Result:= Trunc(StrToDate(sgMenu.Cells[0,ARow]) - StrToDate(sgMenu.Cells[0,BRow]));
+end;
+
procedure TfmMain.sgMenuDblClick(Sender: TObject);
begin
if btEdit.Enabled then
@@ -148,6 +156,7 @@
sgMenu.Cells[0,i]:= DateToStr(MenuPlan.Meal[i-1].Date);
sgMenu.Cells[1,i]:= MenuPlan.Meal[i-1].Dishes.AllDishes.Text;
end;
+ sgMenu.SortColRow(True, 0);
UpdateMenu;
end;
Modified: trunk/u_meal.lfm
===================================================================
--- trunk/u_meal.lfm 2010-08-23 02:22:51 UTC (rev 21)
+++ trunk/u_meal.lfm 2010-08-23 03:55:24 UTC (rev 22)
@@ -6,6 +6,7 @@
Caption = 'Meal'
ClientHeight = 333
ClientWidth = 561
+ OnClose = FormClose
OnCreate = FormCreate
OnShow = FormShow
LCLVersion = '0.9.29'
@@ -209,6 +210,7 @@
Width = 75
Cancel = True
Caption = 'Close'
+ ModalResult = 2
TabOrder = 3
end
object acActions: TActionList
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2010-08-23 02:22:51 UTC (rev 21)
+++ trunk/u_meal.pas 2010-08-23 03:55:24 UTC (rev 22)
@@ -66,6 +66,7 @@
procedure btRemoveClick(Sender: TObject);
procedure btUpClick(Sender: TObject);
procedure cbTypeChange(Sender: TObject);
+ procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
procedure FormCreate(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure lbMealClick(Sender: TObject);
@@ -110,6 +111,11 @@
cbDish.ItemIndex:= 0;
end;
+procedure TfmMeal.FormClose(Sender: TObject; var CloseAction: TCloseAction);
+begin
+ lbMeal.Clear;
+end;
+
procedure TfmMeal.acAddExecute(Sender: TObject);
begin
if not Add then
@@ -118,15 +124,12 @@
procedure TfmMeal.acCloseExecute(Sender: TObject);
begin
-// close the form, after clearing the meal listbox
- lbMeal.Clear;
Close;
end;
procedure TfmMeal.acOKExecute(Sender: TObject);
begin
ModalResult:= mrOK;
- acCloseExecute(Sender);
end;
procedure TfmMeal.acAddAndCloseExecute(Sender: TObject);
@@ -258,12 +261,8 @@
//TODO: it's not editing!!!
if ShowModal = mrOK then
begin
- for i:= 0 to (lbMeal.Count-1) do
- begin
- AMeal.AddDish(Dishes.DishByName(lbMeal.Items.Strings[i]));
- end;
- AMeal.Date:= deDate.Date;
- MenuPlan.Meal[MealIndex]:= AMeal;
+ MenuPlan.RemoveMeal(MealIndex);
+ Add;
end;
end;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2010-08-23 02:22:57
|
Revision: 21
http://gotisso.svn.sourceforge.net/gotisso/?rev=21&view=rev
Author: jmvaz
Date: 2010-08-23 02:22:51 +0000 (Mon, 23 Aug 2010)
Log Message:
-----------
updating to Lazarus snapshot, using new fpc resource style
Modified Paths:
--------------
trunk/gotisso.lpi
trunk/gotisso.lpr
trunk/lang/gotisso.en.po
trunk/lang/gotisso.po
trunk/lang/gotisso.pt_BR.po
trunk/u_ingredients.lfm
trunk/u_ingredients.lrt
trunk/u_ingredients.pas
trunk/u_main.lfm
trunk/u_main.lrt
trunk/u_main.pas
trunk/u_meal.lfm
trunk/u_meal.lrt
trunk/u_meal.pas
Added Paths:
-----------
trunk/bin/
trunk/bin/i386-win32/
trunk/gotisso.ico
trunk/gotisso.res
Removed Paths:
-------------
trunk/gotisso.manifest
trunk/gotisso.rc
trunk/output/languages/
Added: trunk/gotisso.ico
===================================================================
(Binary files differ)
Property changes on: trunk/gotisso.ico
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/gotisso.lpi
===================================================================
--- trunk/gotisso.lpi 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/gotisso.lpi 2010-08-23 02:22:51 UTC (rev 21)
@@ -2,7 +2,7 @@
<CONFIG>
<ProjectOptions>
<PathDelim Value="\"/>
- <Version Value="7"/>
+ <Version Value="8"/>
<General>
<Flags>
<SaveClosedFiles Value="False"/>
@@ -14,15 +14,17 @@
<TargetFileExt Value=".exe"/>
<Title Value="gotisso"/>
<UseAppBundle Value="False"/>
+ <ResourceType Value="res"/>
<UseXPManifest Value="True"/>
+ <Icon Value="0"/>
</General>
<i18n>
<EnableI18N Value="True"/>
<OutDir Value="lang"/>
</i18n>
<VersionInfo>
- <ProjectVersion Value="0.0.0.0"/>
<Language Value="0416"/>
+ <StringTable Comments="" CompanyName="" FileDescription="" FileVersion="0.0.0.0" InternalName="" LegalCopyright="" LegalTrademarks="" OriginalFilename="" ProductName="" ProductVersion="0.0.0.0"/>
</VersionInfo>
<PublishOptions>
<Version Value="2"/>
@@ -90,17 +92,17 @@
</Units>
</ProjectOptions>
<CompilerOptions>
- <Version Value="8"/>
+ <Version Value="9"/>
<PathDelim Value="\"/>
<SearchPaths>
<IncludeFiles Value="$(ProjOutDir)\"/>
- <UnitOutputDirectory Value="\output"/>
+ <UnitOutputDirectory Value="bin\$(TargetCPU)-$(TargetOS)"/>
</SearchPaths>
<Parsing>
<SyntaxOptions>
- <SyntaxMode Value="Delphi"/>
<CStyleOperator Value="False"/>
<AllowLabel Value="False"/>
+ <UseAnsiStrings Value="False"/>
</SyntaxOptions>
</Parsing>
<CodeGeneration>
@@ -128,6 +130,9 @@
<Verbosity>
<ShoLineNum Value="True"/>
</Verbosity>
+ <CompilerMessages>
+ <UseMsgFile Value="True"/>
+ </CompilerMessages>
<CompilerPath Value="$(CompPath)"/>
<CreateMakefileOnBuild Value="True"/>
</Other>
Modified: trunk/gotisso.lpr
===================================================================
--- trunk/gotisso.lpr 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/gotisso.lpr 2010-08-23 02:22:51 UTC (rev 21)
@@ -32,8 +32,10 @@
{ you can add units after this },
Printer4Lazarus, u_main, u_meal, u_ingredients, u_classes, u_consts;
-{$IFDEF WINDOWS}{$R gotisso.rc}{$ENDIF}
+//{$IFDEF WINDOWS}{$R gotisso.rc}{$ENDIF}
+{$R *.res}
+
begin
Application.Title:= sAppTitle;
Application.Initialize;
Deleted: trunk/gotisso.manifest
===================================================================
--- trunk/gotisso.manifest 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/gotisso.manifest 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
- <assemblyIdentity version="1.0.0.0" processorArchitecture="*" name="CompanyName.ProductName.YourApp" type="win32"/>
- <description>Your application description here.</description>
- <dependency>
- <dependentAssembly>
- <assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*"/>
- </dependentAssembly>
- </dependency>
- <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
- <security>
- <requestedPrivileges>
- <requestedExecutionLevel level="asInvoker" uiAccess="false"/>
- </requestedPrivileges>
- </security>
- </trustInfo>
-</assembly>
\ No newline at end of file
Deleted: trunk/gotisso.rc
===================================================================
--- trunk/gotisso.rc 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/gotisso.rc 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,6 +0,0 @@
-#define RT_MANIFEST 24
-#define CREATEPROCESS_MANIFEST_RESOURCE_ID 1
-#define ISOLATIONAWARE_MANIFEST_RESOURCE_ID 2
-#define ISOLATIONAWARE_NOSTATICIMPORT_MANIFEST_RESOURCE_ID 3
-
-CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "gotisso.manifest"
Added: trunk/gotisso.res
===================================================================
(Binary files differ)
Property changes on: trunk/gotisso.res
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/lang/gotisso.en.po
===================================================================
--- trunk/lang/gotisso.en.po 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/lang/gotisso.en.po 2010-08-23 02:22:51 UTC (rev 21)
@@ -21,7 +21,8 @@
msgid "Print..."
msgstr "Print..."
-#: TFMINGREDIENTS.CAPTION
+#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
+msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
msgid "Ingredients"
msgstr "Ingredients"
@@ -62,7 +63,8 @@
msgid "Up"
msgstr "Up"
-#: TFMMAIN.CAPTION
+#: TFMMAIN.FMMAIN.CAPTION
+msgctxt "TFMMAIN.FMMAIN.CAPTION"
msgid "fmMain"
msgstr "Main"
@@ -134,11 +136,6 @@
msgid "Up"
msgstr "Up"
-#: TFMMEAL.CAPTION
-msgctxt "TFMMEAL.CAPTION"
-msgid "Meal"
-msgstr "Meal"
-
#: TFMMEAL.DEDATE.CANCELCAPTION
#| msgid "Cancelar"
msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
@@ -155,6 +152,11 @@
msgid "OK"
msgstr "OK"
+#: TFMMEAL.FMMEAL.CAPTION
+msgctxt "TFMMEAL.FMMEAL.CAPTION"
+msgid "Meal"
+msgstr "Meal"
+
#: TFMMEAL.GBMEAL.CAPTION
msgctxt "TFMMEAL.GBMEAL.CAPTION"
msgid "Meal"
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/lang/gotisso.po 2010-08-23 02:22:51 UTC (rev 21)
@@ -11,7 +11,8 @@
msgid "Print..."
msgstr ""
-#: TFMINGREDIENTS.CAPTION
+#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
+msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
msgid "Ingredients"
msgstr ""
@@ -52,7 +53,8 @@
msgid "Up"
msgstr ""
-#: TFMMAIN.CAPTION
+#: TFMMAIN.FMMAIN.CAPTION
+msgctxt "TFMMAIN.FMMAIN.CAPTION"
msgid "fmMain"
msgstr ""
@@ -123,11 +125,6 @@
msgid "Up"
msgstr ""
-#: TFMMEAL.CAPTION
-msgctxt "TFMMEAL.CAPTION"
-msgid "Meal"
-msgstr ""
-
#: TFMMEAL.DEDATE.CANCELCAPTION
msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
msgid "Cancel"
@@ -142,6 +139,11 @@
msgid "OK"
msgstr ""
+#: TFMMEAL.FMMEAL.CAPTION
+msgctxt "TFMMEAL.FMMEAL.CAPTION"
+msgid "Meal"
+msgstr ""
+
#: TFMMEAL.GBMEAL.CAPTION
msgctxt "TFMMEAL.GBMEAL.CAPTION"
msgid "Meal"
Modified: trunk/lang/gotisso.pt_BR.po
===================================================================
--- trunk/lang/gotisso.pt_BR.po 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/lang/gotisso.pt_BR.po 2010-08-23 02:22:51 UTC (rev 21)
@@ -24,8 +24,8 @@
msgid "Print..."
msgstr "Imprimir..."
-#: TFMINGREDIENTS.CAPTION
-#| msgid "Ingredientes"
+#: TFMINGREDIENTS.FMINGREDIENTS.CAPTION
+msgctxt "TFMINGREDIENTS.FMINGREDIENTS.CAPTION"
msgid "Ingredients"
msgstr "Ingredientes"
@@ -70,7 +70,8 @@
msgid "Up"
msgstr "Para cima"
-#: TFMMAIN.CAPTION
+#: TFMMAIN.FMMAIN.CAPTION
+msgctxt "TFMMAIN.FMMAIN.CAPTION"
msgid "fmMain"
msgstr "Principal"
@@ -149,12 +150,6 @@
msgid "Up"
msgstr "Para cima"
-#: TFMMEAL.CAPTION
-#| msgid "Refeição"
-msgctxt "TFMMEAL.CAPTION"
-msgid "Meal"
-msgstr "Refeição"
-
#: TFMMEAL.DEDATE.CANCELCAPTION
#| msgid "Cancelar"
msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
@@ -171,6 +166,11 @@
msgid "OK"
msgstr "OK"
+#: TFMMEAL.FMMEAL.CAPTION
+msgctxt "TFMMEAL.FMMEAL.CAPTION"
+msgid "Meal"
+msgstr "Refeição"
+
#: TFMMEAL.GBMEAL.CAPTION
#| msgid "Refeição"
msgctxt "TFMMEAL.GBMEAL.CAPTION"
Modified: trunk/u_ingredients.lfm
===================================================================
--- trunk/u_ingredients.lfm 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_ingredients.lfm 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,12 +1,12 @@
object fmIngredients: TfmIngredients
- Left = 533
+ Left = 500
Height = 300
- Top = 240
+ Top = 255
Width = 400
Caption = 'Ingredients'
ClientHeight = 300
ClientWidth = 400
- LCLVersion = '0.9.28.2'
+ LCLVersion = '0.9.29'
object lbIngredients: TListBox
Left = 24
Height = 218
Modified: trunk/u_ingredients.lrt
===================================================================
--- trunk/u_ingredients.lrt 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_ingredients.lrt 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,3 +1,3 @@
-TFMINGREDIENTS.CAPTION=Ingredients
+TFMINGREDIENTS.FMINGREDIENTS.CAPTION=Ingredients
TFMINGREDIENTS.BTPRINT.CAPTION=Print...
TFMINGREDIENTS.BTCLOSE.CAPTION=Close
Modified: trunk/u_ingredients.pas
===================================================================
--- trunk/u_ingredients.pas 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_ingredients.pas 2010-08-23 02:22:51 UTC (rev 21)
@@ -50,6 +50,8 @@
implementation
+{$R *.lfm}
+
{ TfmIngredients }
procedure TfmIngredients.btPrintClick(Sender: TObject);
@@ -65,8 +67,5 @@
Close;
end;
-initialization
- {$I u_ingredients.lrs}
-
end.
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_main.lfm 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,7 +1,7 @@
object fmMain: TfmMain
- Left = 292
+ Left = 287
Height = 462
- Top = 184
+ Top = 215
Width = 819
Caption = 'fmMain'
ClientHeight = 462
@@ -11,7 +11,7 @@
OnShow = FormShow
Position = poScreenCenter
ShowHint = True
- LCLVersion = '0.9.28.2'
+ LCLVersion = '0.9.29'
object gbMenu: TGroupBox
Left = 24
Height = 408
Modified: trunk/u_main.lrt
===================================================================
--- trunk/u_main.lrt 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_main.lrt 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,4 +1,4 @@
-TFMMAIN.CAPTION=fmMain
+TFMMAIN.FMMAIN.CAPTION=fmMain
TFMMAIN.GBMENU.CAPTION=Menu
TFMMAIN.BTNEW.CAPTION=New...
TFMMAIN.BTDOWN.CAPTION=Down
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_main.pas 2010-08-23 02:22:51 UTC (rev 21)
@@ -71,6 +71,8 @@
implementation
+{$R *.lfm}
+
uses u_classes, StringGridPrinter, u_ingredients, u_meal, u_consts;
{ TfmMain }
@@ -227,9 +229,6 @@
FillMenuGrid;
end;
-initialization
- {$I u_main.lrs}
-
end.
Modified: trunk/u_meal.lfm
===================================================================
--- trunk/u_meal.lfm 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_meal.lfm 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,14 +1,14 @@
object fmMeal: TfmMeal
- Left = 378
+ Left = 343
Height = 333
- Top = 257
+ Top = 266
Width = 561
Caption = 'Meal'
ClientHeight = 333
ClientWidth = 561
OnCreate = FormCreate
OnShow = FormShow
- LCLVersion = '0.9.28.2'
+ LCLVersion = '0.9.29'
object gbMeal: TGroupBox
Left = 20
Height = 240
@@ -75,6 +75,7 @@
DefaultToday = True
DateOrder = doDMY
ButtonWidth = 23
+ CharCase = ecNormal
Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100
2000000000000004000064000000640000000000000000000000FFFFFF00FFFF
@@ -112,6 +113,7 @@
FF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00FFFFFF00
}
NumGlyphs = 0
+ MaxLength = 10
TabOrder = 1
end
object cbDish: TComboBox
Modified: trunk/u_meal.lrt
===================================================================
--- trunk/u_meal.lrt 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_meal.lrt 2010-08-23 02:22:51 UTC (rev 21)
@@ -1,4 +1,4 @@
-TFMMEAL.CAPTION=Meal
+TFMMEAL.FMMEAL.CAPTION=Meal
TFMMEAL.GBMEAL.CAPTION=Meal
TFMMEAL.LBTYPE.CAPTION=Dish Type:
TFMMEAL.LBDISH.CAPTION=Dish:
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-14 02:27:07 UTC (rev 20)
+++ trunk/u_meal.pas 2010-08-23 02:22:51 UTC (rev 21)
@@ -85,6 +85,8 @@
implementation
+{$R *.lfm}
+
uses
u_classes, u_consts;
@@ -108,7 +110,6 @@
cbDish.ItemIndex:= 0;
end;
-
procedure TfmMeal.acAddExecute(Sender: TObject);
begin
if not Add then
@@ -266,8 +267,5 @@
end;
end;
-initialization
- {$I u_meal.lrs}
-
end.
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-14 02:27:18
|
Revision: 20
http://gotisso.svn.sourceforge.net/gotisso/?rev=20&view=rev
Author: jmvaz
Date: 2009-12-14 02:27:07 +0000 (Mon, 14 Dec 2009)
Log Message:
-----------
now we can edit the meal (but it's not working properly yet)
Modified Paths:
--------------
trunk/lang/gotisso.en.po
trunk/lang/gotisso.po
trunk/lang/gotisso.pt_BR.po
trunk/output/languages/gotisso.en.mo
trunk/output/languages/gotisso.pt_BR.mo
trunk/u_classes.pas
trunk/u_ingredients.lfm
trunk/u_main.lfm
trunk/u_main.lrt
trunk/u_main.pas
trunk/u_meal.lfm
trunk/u_meal.lrt
trunk/u_meal.pas
Modified: trunk/lang/gotisso.en.po
===================================================================
--- trunk/lang/gotisso.en.po 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/lang/gotisso.en.po 2009-12-14 02:27:07 UTC (rev 20)
@@ -35,6 +35,10 @@
msgid "Down"
msgstr "Down"
+#: TFMMAIN.BTEDIT.CAPTION
+msgid "Edit..."
+msgstr "Edit..."
+
#: TFMMAIN.BTINGREDIENTS.CAPTION
msgid "Ingredients List..."
msgstr "Ingredients List..."
@@ -67,15 +71,39 @@
msgid "Menu"
msgstr "Menu"
-#: TFMMEAL.BTADD.CAPTION
-msgctxt "TFMMEAL.BTADD.CAPTION"
+#: TFMMEAL.ACADD.CAPTION
+msgctxt "TFMMEAL.ACADD.CAPTION"
msgid "Add"
msgstr "Add"
-#: TFMMEAL.BTADDANDCLOSE.CAPTION
+#: TFMMEAL.ACADDANDCLOSE.CAPTION
+msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
msgid "Add and Close"
msgstr "Add and Close"
+#: TFMMEAL.ACCANCEL.CAPTION
+msgctxt "TFMMEAL.ACCANCEL.CAPTION"
+msgid "Cancel"
+msgstr "Cancel"
+
+#: TFMMEAL.ACCLOSE.CAPTION
+msgctxt "TFMMEAL.ACCLOSE.CAPTION"
+msgid "Close"
+msgstr "Close"
+
+#: TFMMEAL.ACOK.CAPTION
+msgctxt "TFMMEAL.ACOK.CAPTION"
+msgid "OK"
+msgstr "OK"
+
+#: TFMMEAL.BTACTION.CAPTION
+msgid "Action"
+msgstr ""
+
+#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
+msgid "Action and Close"
+msgstr ""
+
#: TFMMEAL.BTADDDISH.CAPTION
msgctxt "TFMMEAL.BTADDDISH.CAPTION"
msgid "Add"
@@ -113,6 +141,7 @@
#: TFMMEAL.DEDATE.CANCELCAPTION
#| msgid "Cancelar"
+msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
msgid "Cancel"
msgstr "Cancel"
@@ -122,6 +151,7 @@
msgstr "Choose the Date"
#: TFMMEAL.DEDATE.OKCAPTION
+msgctxt "TFMMEAL.DEDATE.OKCAPTION"
msgid "OK"
msgstr "OK"
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/lang/gotisso.po 2009-12-14 02:27:07 UTC (rev 20)
@@ -25,6 +25,10 @@
msgid "Down"
msgstr ""
+#: TFMMAIN.BTEDIT.CAPTION
+msgid "Edit..."
+msgstr ""
+
#: TFMMAIN.BTINGREDIENTS.CAPTION
msgid "Ingredients List..."
msgstr ""
@@ -56,15 +60,39 @@
msgid "Menu"
msgstr ""
-#: TFMMEAL.BTADD.CAPTION
-msgctxt "TFMMEAL.BTADD.CAPTION"
+#: TFMMEAL.ACADD.CAPTION
+msgctxt "TFMMEAL.ACADD.CAPTION"
msgid "Add"
msgstr ""
-#: TFMMEAL.BTADDANDCLOSE.CAPTION
+#: TFMMEAL.ACADDANDCLOSE.CAPTION
+msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
msgid "Add and Close"
msgstr ""
+#: TFMMEAL.ACCANCEL.CAPTION
+msgctxt "TFMMEAL.ACCANCEL.CAPTION"
+msgid "Cancel"
+msgstr ""
+
+#: TFMMEAL.ACCLOSE.CAPTION
+msgctxt "TFMMEAL.ACCLOSE.CAPTION"
+msgid "Close"
+msgstr ""
+
+#: TFMMEAL.ACOK.CAPTION
+msgctxt "TFMMEAL.ACOK.CAPTION"
+msgid "OK"
+msgstr ""
+
+#: TFMMEAL.BTACTION.CAPTION
+msgid "Action"
+msgstr ""
+
+#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
+msgid "Action and Close"
+msgstr ""
+
#: TFMMEAL.BTADDDISH.CAPTION
msgctxt "TFMMEAL.BTADDDISH.CAPTION"
msgid "Add"
@@ -101,6 +129,7 @@
msgstr ""
#: TFMMEAL.DEDATE.CANCELCAPTION
+msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
msgid "Cancel"
msgstr ""
@@ -109,6 +138,7 @@
msgstr ""
#: TFMMEAL.DEDATE.OKCAPTION
+msgctxt "TFMMEAL.DEDATE.OKCAPTION"
msgid "OK"
msgstr ""
Modified: trunk/lang/gotisso.pt_BR.po
===================================================================
--- trunk/lang/gotisso.pt_BR.po 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/lang/gotisso.pt_BR.po 2009-12-14 02:27:07 UTC (rev 20)
@@ -40,6 +40,10 @@
msgid "Down"
msgstr "Para baixo"
+#: TFMMAIN.BTEDIT.CAPTION
+msgid "Edit..."
+msgstr "Editar..."
+
#: TFMMAIN.BTINGREDIENTS.CAPTION
#| msgid "Lista de Ingredientes..."
msgid "Ingredients List..."
@@ -76,17 +80,39 @@
msgid "Menu"
msgstr "Cardápio"
-#: TFMMEAL.BTADD.CAPTION
-#| msgid "Adicionar"
-msgctxt "TFMMEAL.BTADD.CAPTION"
+#: TFMMEAL.ACADD.CAPTION
+msgctxt "TFMMEAL.ACADD.CAPTION"
msgid "Add"
msgstr "Adicionar"
-#: TFMMEAL.BTADDANDCLOSE.CAPTION
-#| msgid "Adicionar e Fechar"
+#: TFMMEAL.ACADDANDCLOSE.CAPTION
+msgctxt "TFMMEAL.ACADDANDCLOSE.CAPTION"
msgid "Add and Close"
msgstr "Adicionar e Fechar"
+#: TFMMEAL.ACCANCEL.CAPTION
+msgctxt "TFMMEAL.ACCANCEL.CAPTION"
+msgid "Cancel"
+msgstr "Cancelar"
+
+#: TFMMEAL.ACCLOSE.CAPTION
+msgctxt "TFMMEAL.ACCLOSE.CAPTION"
+msgid "Close"
+msgstr "Fechar"
+
+#: TFMMEAL.ACOK.CAPTION
+msgctxt "TFMMEAL.ACOK.CAPTION"
+msgid "OK"
+msgstr "OK"
+
+#: TFMMEAL.BTACTION.CAPTION
+msgid "Action"
+msgstr ""
+
+#: TFMMEAL.BTACTIONANDCLOSE.CAPTION
+msgid "Action and Close"
+msgstr ""
+
#: TFMMEAL.BTADDDISH.CAPTION
#| msgid "Adicionar"
msgctxt "TFMMEAL.BTADDDISH.CAPTION"
@@ -131,6 +157,7 @@
#: TFMMEAL.DEDATE.CANCELCAPTION
#| msgid "Cancelar"
+msgctxt "TFMMEAL.DEDATE.CANCELCAPTION"
msgid "Cancel"
msgstr "Cancelar"
@@ -140,8 +167,9 @@
msgstr "Escolha a data"
#: TFMMEAL.DEDATE.OKCAPTION
+msgctxt "TFMMEAL.DEDATE.OKCAPTION"
msgid "OK"
-msgstr "Aceitar"
+msgstr "OK"
#: TFMMEAL.GBMEAL.CAPTION
#| msgid "Refeição"
Modified: trunk/output/languages/gotisso.en.mo
===================================================================
(Binary files differ)
Modified: trunk/output/languages/gotisso.pt_BR.mo
===================================================================
(Binary files differ)
Modified: trunk/u_classes.pas
===================================================================
--- trunk/u_classes.pas 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_classes.pas 2009-12-14 02:27:07 UTC (rev 20)
@@ -117,6 +117,7 @@
fList: TStringList;
function GetCount: Integer;
function GetMeal(Index: Integer): TMeal;
+ procedure SetMeal(Index: Integer; const AValue: TMeal);
protected
public
@@ -126,7 +127,7 @@
procedure Clear;
function RemoveMeal(AIndex: Integer): Boolean;
property Count: Integer read GetCount;
- property Meal[Index: Integer]: TMeal read GetMeal;
+ property Meal[Index: Integer]: TMeal read GetMeal write SetMeal;
end;
var
@@ -413,6 +414,15 @@
Result:= (fList.Objects[Index] as TMeal);
end;
+procedure TMenuPlan.SetMeal(Index: Integer; const AValue: TMeal);
+begin
+ if ((Index >= 0) and (Index < fList.Count)) then
+ begin
+ (fList.Objects[Index] as TMeal).Date:= AValue.Date;
+ (fList.Objects[Index] as TMeal).Dishes:= AValue.Dishes;
+ end;
+End;
+
constructor TMenuPlan.Create;
begin
inherited Create;
Modified: trunk/u_ingredients.lfm
===================================================================
--- trunk/u_ingredients.lfm 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_ingredients.lfm 2009-12-14 02:27:07 UTC (rev 20)
@@ -1,7 +1,7 @@
object fmIngredients: TfmIngredients
- Left = 392
+ Left = 533
Height = 300
- Top = 253
+ Top = 240
Width = 400
Caption = 'Ingredients'
ClientHeight = 300
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_main.lfm 2009-12-14 02:27:07 UTC (rev 20)
@@ -1,7 +1,7 @@
object fmMain: TfmMain
- Left = 315
+ Left = 292
Height = 462
- Top = 202
+ Top = 184
Width = 819
Caption = 'fmMain'
ClientHeight = 462
@@ -34,6 +34,7 @@
TabOrder = 0
TitleStyle = tsStandard
OnClick = sgMenuClick
+ OnDblClick = sgMenuDblClick
end
object btNew: TButton
Left = 686
@@ -48,7 +49,7 @@
object btDown: TButton
Left = 686
Height = 25
- Top = 96
+ Top = 128
Width = 75
Anchors = [akTop, akRight]
Caption = 'Down'
@@ -58,7 +59,7 @@
object btClear: TButton
Left = 686
Height = 25
- Top = 184
+ Top = 208
Width = 75
Anchors = [akTop, akRight]
Caption = 'Clear'
@@ -68,7 +69,7 @@
object btUp: TButton
Left = 686
Height = 25
- Top = 64
+ Top = 96
Width = 75
Anchors = [akTop, akRight]
Caption = 'Up'
@@ -98,7 +99,7 @@
object btRemove: TButton
Left = 686
Height = 25
- Top = 128
+ Top = 160
Width = 75
Anchors = [akTop, akRight]
Caption = 'Remove'
@@ -106,6 +107,16 @@
TabOrder = 7
end
end
+ object btEdit: TButton
+ Left = 712
+ Height = 25
+ Top = 112
+ Width = 75
+ Anchors = [akTop, akRight]
+ Caption = 'Edit...'
+ OnClick = btEditClick
+ TabOrder = 1
+ end
object PrintDialog: TPrintDialog
left = 528
top = 8
Modified: trunk/u_main.lrt
===================================================================
--- trunk/u_main.lrt 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_main.lrt 2009-12-14 02:27:07 UTC (rev 20)
@@ -7,3 +7,4 @@
TFMMAIN.BTPRINT.CAPTION=Print...
TFMMAIN.BTINGREDIENTS.CAPTION=Ingredients List...
TFMMAIN.BTREMOVE.CAPTION=Remove
+TFMMAIN.BTEDIT.CAPTION=Edit...
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_main.pas 2009-12-14 02:27:07 UTC (rev 20)
@@ -37,6 +37,7 @@
btNew: TButton;
btDown: TButton;
btClear: TButton;
+ btEdit: TButton;
btUp: TButton;
btPrint: TButton;
btRemove: TButton;
@@ -45,6 +46,7 @@
sgMenu: TStringGrid;
procedure btClearClick(Sender: TObject);
procedure btDownClick(Sender: TObject);
+ procedure btEditClick(Sender: TObject);
procedure btPrintClick(Sender: TObject);
procedure btIngredientsClick(Sender: TObject);
procedure btNewClick(Sender: TObject);
@@ -54,6 +56,7 @@
procedure FormDestroy(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure sgMenuClick(Sender: TObject);
+ procedure sgMenuDblClick(Sender: TObject);
private
{ private declarations }
@@ -113,12 +116,21 @@
UpdateMenu;
end;
+procedure TfmMain.sgMenuDblClick(Sender: TObject);
+begin
+ if btEdit.Enabled then
+ begin
+ btEditClick(Sender);
+ end;
+end;
+
procedure TfmMain.UpdateMenu;
begin
// enable or disable the buttons depending on the dish count or dish selected position
+ btEdit.Enabled:= ((sgMenu.IsCellSelected[0,sgMenu.Row]) and (not sgMenu.IsCellSelected[0,0]));
btUp.Enabled:= ((sgMenu.IsCellSelected[0,sgMenu.Row]) and (not (sgMenu.IsCellSelected[0,1] or sgMenu.IsCellSelected[0,0])));
btDown.Enabled:= ((sgMenu.IsCellSelected[0,sgMenu.Row]) and (not sgMenu.IsCellSelected[0,sgMenu.RowCount-1]));
- btRemove.Enabled:= ((sgMenu.IsCellSelected[0,sgMenu.Row]) and (not sgMenu.IsCellSelected[0,0]));
+ btRemove.Enabled:= btEdit.Enabled;
btClear.Enabled:= (sgMenu.RowCount > 1);
btPrint.Enabled:= btClear.Enabled;
btIngredients.Enabled:= btClear.Enabled;
@@ -165,6 +177,17 @@
FillMenuGrid;
end;
+procedure TfmMain.btEditClick(Sender: TObject);
+begin
+ with TfmMeal.Create(Application) do
+ try
+ Edit(sgMenu.Row-1);
+ FillMenuGrid;
+ finally
+ Release;
+ end;
+end;
+
procedure TfmMain.btClearClick(Sender: TObject);
begin
MenuPlan.Clear;
@@ -185,7 +208,7 @@
begin
with TfmMeal.Create(Application) do
try
- ShowModal;
+ New;
FillMenuGrid;
finally
Release;
Modified: trunk/u_meal.lfm
===================================================================
--- trunk/u_meal.lfm 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_meal.lfm 2009-12-14 02:27:07 UTC (rev 20)
@@ -1,7 +1,7 @@
object fmMeal: TfmMeal
- Left = 362
+ Left = 378
Height = 333
- Top = 246
+ Top = 257
Width = 561
Caption = 'Meal'
ClientHeight = 333
@@ -183,23 +183,21 @@
TabOrder = 8
end
end
- object btAdd: TButton
- Left = 24
+ object btAction: TButton
+ Left = 256
Height = 25
Top = 280
Width = 75
- Caption = 'Add'
+ Caption = 'Action'
Default = True
- OnClick = btAddClick
TabOrder = 1
end
- object btAddAndClose: TButton
- Left = 128
+ object btActionAndClose: TButton
+ Left = 344
Height = 25
Top = 280
Width = 107
- Caption = 'Add and Close'
- OnClick = btAddAndCloseClick
+ Caption = 'Action and Close'
TabOrder = 2
end
object btClose: TButton
@@ -209,7 +207,30 @@
Width = 75
Cancel = True
Caption = 'Close'
- OnClick = btCloseClick
TabOrder = 3
end
+ object acActions: TActionList
+ left = 56
+ top = 224
+ object acAdd: TAction
+ Caption = 'Add'
+ OnExecute = acAddExecute
+ end
+ object acOK: TAction
+ Caption = 'OK'
+ OnExecute = acOKExecute
+ end
+ object acClose: TAction
+ Caption = 'Close'
+ OnExecute = acCloseExecute
+ end
+ object acCancel: TAction
+ Caption = 'Cancel'
+ OnExecute = acCloseExecute
+ end
+ object acAddAndClose: TAction
+ Caption = 'Add and Close'
+ OnExecute = acAddAndCloseExecute
+ end
+ end
end
Modified: trunk/u_meal.lrt
===================================================================
--- trunk/u_meal.lrt 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_meal.lrt 2009-12-14 02:27:07 UTC (rev 20)
@@ -12,6 +12,11 @@
TFMMEAL.BTUP.CAPTION=Up
TFMMEAL.BTREMOVE.CAPTION=Remove
TFMMEAL.BTCLEAR.CAPTION=Clear
-TFMMEAL.BTADD.CAPTION=Add
-TFMMEAL.BTADDANDCLOSE.CAPTION=Add and Close
+TFMMEAL.BTACTION.CAPTION=Action
+TFMMEAL.BTACTIONANDCLOSE.CAPTION=Action and Close
TFMMEAL.BTCLOSE.CAPTION=Close
+TFMMEAL.ACADD.CAPTION=Add
+TFMMEAL.ACOK.CAPTION=OK
+TFMMEAL.ACCLOSE.CAPTION=Close
+TFMMEAL.ACCANCEL.CAPTION=Cancel
+TFMMEAL.ACADDANDCLOSE.CAPTION=Add and Close
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-10 02:41:25 UTC (rev 19)
+++ trunk/u_meal.pas 2009-12-14 02:27:07 UTC (rev 20)
@@ -33,13 +33,19 @@
{ TfmMeal }
TfmMeal = class(TForm)
+ acActions: TActionList;
+ acAdd: TAction;
+ acOK: TAction;
+ acClose: TAction;
+ acCancel: TAction;
+ acAddAndClose: TAction;
btAddDish: TButton;
- btAdd: TButton;
+ btAction: TButton;
btClear: TButton;
btRemove: TButton;
btDown: TButton;
btUp: TButton;
- btAddAndClose: TButton;
+ btActionAndClose: TButton;
btClose: TButton;
cbDish: TComboBox;
cbType: TComboBox;
@@ -50,10 +56,11 @@
lbDish: TLabel;
lbMeal: TListBox;
lbType: TLabel;
- procedure btAddClick(Sender: TObject);
- procedure btAddAndCloseClick(Sender: TObject);
+ procedure acAddAndCloseExecute(Sender: TObject);
+ procedure acAddExecute(Sender: TObject);
+ procedure acCloseExecute(Sender: TObject);
+ procedure acOKExecute(Sender: TObject);
procedure btDownClick(Sender: TObject);
- procedure btCloseClick(Sender: TObject);
procedure btAddDishClick(Sender: TObject);
procedure btClearClick(Sender: TObject);
procedure btRemoveClick(Sender: TObject);
@@ -64,10 +71,13 @@
procedure lbMealClick(Sender: TObject);
private
{ private declarations }
+ editing: Boolean;
procedure UpdateMeal;
function Add: Boolean;
public
{ public declarations }
+ procedure New;
+ procedure Edit(MealIndex: Integer);
end;
var
@@ -99,21 +109,31 @@
end;
-procedure TfmMeal.btAddClick(Sender: TObject);
+procedure TfmMeal.acAddExecute(Sender: TObject);
begin
if not Add then
ShowMessage(sError);
end;
-procedure TfmMeal.btAddAndCloseClick(Sender: TObject);
+procedure TfmMeal.acCloseExecute(Sender: TObject);
begin
+// close the form, after clearing the meal listbox
+ lbMeal.Clear;
+ Close;
+end;
+
+procedure TfmMeal.acOKExecute(Sender: TObject);
+begin
+ ModalResult:= mrOK;
+ acCloseExecute(Sender);
+end;
+
+procedure TfmMeal.acAddAndCloseExecute(Sender: TObject);
+begin
if not Add then
ShowMessage(sError)
else
- begin
- lbMeal.Clear;
- Close;
- end;
+ acCloseExecute(Sender);
end;
procedure TfmMeal.btDownClick(Sender: TObject);
@@ -131,13 +151,6 @@
UpdateMeal;
end;
-procedure TfmMeal.btCloseClick(Sender: TObject);
-begin
-// close the form, after clearing the meal listbox
- lbMeal.Clear;
- Close;
-end;
-
procedure TfmMeal.btAddDishClick(Sender: TObject);
begin
// add choosed dish to the meal listbox
@@ -191,8 +204,8 @@
btDown.Enabled:= ((lbMeal.SelCount > 0) and (not lbMeal.Selected[lbMeal.Count-1]));
btRemove.Enabled:= (lbMeal.SelCount > 0);
btClear.Enabled:= (lbMeal.Count > 0);
- btAdd.Enabled:= (lbMeal.Items.Count > 0);
- btAddAndClose.Enabled:= btAdd.Enabled;
+ btAction.Enabled:= (lbMeal.Items.Count > 0);
+ btActionAndClose.Enabled:= btAction.Enabled;
end;
function TfmMeal.Add: Boolean;
@@ -220,6 +233,39 @@
end;
end;
+procedure TfmMeal.New;
+begin
+ deDate.Date:= Now;
+ lbMeal.Clear;
+ btAction.Action:= acAdd;
+ btActionAndClose.Action:= acAddAndClose;
+ btClose.Action:= acClose;
+ ShowModal;
+end;
+
+procedure TfmMeal.Edit(MealIndex: Integer);
+var
+ AMeal: TMeal;
+ i: Integer;
+begin
+ AMeal:= MenuPlan.Meal[MealIndex];
+ deDate.Date:= AMeal.Date;
+ lbMeal.Items.Assign(AMeal.Dishes.AllDishes);
+ btAction.Action:= acOK;
+ btActionAndClose.Visible:= False;
+ btClose.Action:= acCancel;
+ //TODO: it's not editing!!!
+ if ShowModal = mrOK then
+ begin
+ for i:= 0 to (lbMeal.Count-1) do
+ begin
+ AMeal.AddDish(Dishes.DishByName(lbMeal.Items.Strings[i]));
+ end;
+ AMeal.Date:= deDate.Date;
+ MenuPlan.Meal[MealIndex]:= AMeal;
+ end;
+end;
+
initialization
{$I u_meal.lrs}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-10 02:41:31
|
Revision: 19
http://gotisso.svn.sourceforge.net/gotisso/?rev=19&view=rev
Author: jmvaz
Date: 2009-12-10 02:41:25 +0000 (Thu, 10 Dec 2009)
Log Message:
-----------
localization added (en, pt_BR)
Modified Paths:
--------------
trunk/lang/gotisso.en.po
trunk/lang/gotisso.po
trunk/lang/gotisso.pt_BR.po
trunk/u_classes.pas
trunk/u_consts.pas
trunk/u_ingredients.lfm
trunk/u_ingredients.lrt
trunk/u_main.lfm
trunk/u_main.lrt
trunk/u_main.pas
trunk/u_meal.lfm
trunk/u_meal.lrt
trunk/u_meal.pas
Added Paths:
-----------
trunk/output/languages/gotisso.en.mo
trunk/output/languages/gotisso.pt_BR.mo
trunk/output/languages/lclstrconsts.pt_BR.mo
Removed Paths:
-------------
trunk/output/languages/en/
trunk/output/languages/pt_BR/
Modified: trunk/lang/gotisso.en.po
===================================================================
--- trunk/lang/gotisso.en.po 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/lang/gotisso.en.po 2009-12-10 02:41:25 UTC (rev 19)
@@ -1,55 +1,60 @@
msgid ""
msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
-"Project-Id-Version: \n"
+"Project-Id-Version: Gotosso Meal Planner\n"
"POT-Creation-Date: \n"
"PO-Revision-Date: \n"
"Last-Translator: João Marcelo S. Vaz <jm...@gm...>\n"
-"Language-Team: \n"
+"Language-Team: João Marcelo S. Vaz\n"
"MIME-Version: 1.0\n"
"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-Language: English\n"
+"X-Poedit-Country: UNITED STATES\n"
#: TFMINGREDIENTS.BTCLOSE.CAPTION
msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
-msgid "Fechar"
+msgid "Close"
msgstr "Close"
#: TFMINGREDIENTS.BTPRINT.CAPTION
msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
-msgid "Imprimir..."
+msgid "Print..."
msgstr "Print..."
#: TFMINGREDIENTS.CAPTION
-msgid "Ingredientes"
+msgid "Ingredients"
msgstr "Ingredients"
#: TFMMAIN.BTCLEAR.CAPTION
msgctxt "TFMMAIN.BTCLEAR.CAPTION"
-msgid "Limpar"
+msgid "Clear"
msgstr "Clear"
#: TFMMAIN.BTDOWN.CAPTION
+msgctxt "TFMMAIN.BTDOWN.CAPTION"
msgid "Down"
msgstr "Down"
#: TFMMAIN.BTINGREDIENTS.CAPTION
-msgid "Lista de Ingredientes..."
+msgid "Ingredients List..."
msgstr "Ingredients List..."
#: TFMMAIN.BTNEW.CAPTION
-msgid "Nova..."
+msgid "New..."
msgstr "New..."
#: TFMMAIN.BTPRINT.CAPTION
msgctxt "TFMMAIN.BTPRINT.CAPTION"
-msgid "Imprimir..."
+msgid "Print..."
msgstr "Print..."
#: TFMMAIN.BTREMOVE.CAPTION
+msgctxt "TFMMAIN.BTREMOVE.CAPTION"
msgid "Remove"
msgstr "Remove"
#: TFMMAIN.BTUP.CAPTION
+msgctxt "TFMMAIN.BTUP.CAPTION"
msgid "Up"
msgstr "Up"
@@ -59,59 +64,61 @@
#: TFMMAIN.GBMENU.CAPTION
msgctxt "TFMMAIN.GBMENU.CAPTION"
-msgid "Cardápio"
+msgid "Menu"
msgstr "Menu"
-#: TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION
-msgid "Pratos"
-msgstr "Dishes"
-
#: TFMMEAL.BTADD.CAPTION
msgctxt "TFMMEAL.BTADD.CAPTION"
-msgid "Adicionar"
+msgid "Add"
msgstr "Add"
#: TFMMEAL.BTADDANDCLOSE.CAPTION
-msgid "Adicionar e Fechar"
+msgid "Add and Close"
msgstr "Add and Close"
#: TFMMEAL.BTADDDISH.CAPTION
msgctxt "TFMMEAL.BTADDDISH.CAPTION"
-msgid "Adicionar"
+msgid "Add"
msgstr "Add"
#: TFMMEAL.BTCLEAR.CAPTION
msgctxt "TFMMEAL.BTCLEAR.CAPTION"
-msgid "Limpar"
+msgid "Clear"
msgstr "Clear"
#: TFMMEAL.BTCLOSE.CAPTION
msgctxt "TFMMEAL.BTCLOSE.CAPTION"
-msgid "Fechar"
+msgid "Close"
msgstr "Close"
#: TFMMEAL.BTDOWN.CAPTION
-msgid "Abaixo"
+msgctxt "TFMMEAL.BTDOWN.CAPTION"
+msgid "Down"
msgstr "Down"
#: TFMMEAL.BTREMOVE.CAPTION
-msgid "Remover"
+msgctxt "TFMMEAL.BTREMOVE.CAPTION"
+msgid "Remove"
msgstr "Remove"
#: TFMMEAL.BTUP.CAPTION
-msgid "Acima"
+msgctxt "TFMMEAL.BTUP.CAPTION"
+msgid "Up"
msgstr "Up"
#: TFMMEAL.CAPTION
-msgid "fmMeal"
+msgctxt "TFMMEAL.CAPTION"
+msgid "Meal"
msgstr "Meal"
#: TFMMEAL.DEDATE.CANCELCAPTION
-msgid "Cancelar"
+#| msgid "Cancelar"
+msgid "Cancel"
msgstr "Cancel"
#: TFMMEAL.DEDATE.DIALOGTITLE
-msgid "Escolha a data"
+#| msgid "Escolha a data"
+msgid "Choose the date"
msgstr "Choose the Date"
#: TFMMEAL.DEDATE.OKCAPTION
@@ -119,21 +126,36 @@
msgstr "OK"
#: TFMMEAL.GBMEAL.CAPTION
-msgid "Refeição"
+msgctxt "TFMMEAL.GBMEAL.CAPTION"
+msgid "Meal"
msgstr "Meal"
+#: TFMMEAL.LBDATE.CAPTION
+msgid "Date:"
+msgstr "Date:"
+
#: TFMMEAL.LBDISH.CAPTION
-msgid "Prato:"
+msgid "Dish:"
msgstr "Dish:"
#: TFMMEAL.LBLMEAL.CAPTION
-msgid "Refeição:"
+msgid "Meal:"
msgstr "Meal:"
#: TFMMEAL.LBTYPE.CAPTION
-msgid "Tipo:"
+msgid "Dish Type:"
msgstr "Dish Type:"
+#: u_consts.sdate
+#| msgid "Data"
+msgid "Date"
+msgstr "Date"
+
+#: u_consts.sdishes
+#| msgid "Pratos"
+msgid "Dishes"
+msgstr "Dishes"
+
#: u_consts.serror
msgid "Error!!!"
msgstr "Error!!!"
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/lang/gotisso.po 2009-12-10 02:41:25 UTC (rev 19)
@@ -3,45 +3,48 @@
#: TFMINGREDIENTS.BTCLOSE.CAPTION
msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
-msgid "Fechar"
+msgid "Close"
msgstr ""
#: TFMINGREDIENTS.BTPRINT.CAPTION
msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
-msgid "Imprimir..."
+msgid "Print..."
msgstr ""
#: TFMINGREDIENTS.CAPTION
-msgid "Ingredientes"
+msgid "Ingredients"
msgstr ""
#: TFMMAIN.BTCLEAR.CAPTION
msgctxt "TFMMAIN.BTCLEAR.CAPTION"
-msgid "Limpar"
+msgid "Clear"
msgstr ""
#: TFMMAIN.BTDOWN.CAPTION
+msgctxt "TFMMAIN.BTDOWN.CAPTION"
msgid "Down"
msgstr ""
#: TFMMAIN.BTINGREDIENTS.CAPTION
-msgid "Lista de Ingredientes..."
+msgid "Ingredients List..."
msgstr ""
#: TFMMAIN.BTNEW.CAPTION
-msgid "Nova..."
+msgid "New..."
msgstr ""
#: TFMMAIN.BTPRINT.CAPTION
msgctxt "TFMMAIN.BTPRINT.CAPTION"
-msgid "Imprimir..."
+msgid "Print..."
msgstr ""
#: TFMMAIN.BTREMOVE.CAPTION
+msgctxt "TFMMAIN.BTREMOVE.CAPTION"
msgid "Remove"
msgstr ""
#: TFMMAIN.BTUP.CAPTION
+msgctxt "TFMMAIN.BTUP.CAPTION"
msgid "Up"
msgstr ""
@@ -50,60 +53,59 @@
msgstr ""
#: TFMMAIN.GBMENU.CAPTION
-msgctxt "TFMMAIN.GBMENU.CAPTION"
-msgid "Cardápio"
+msgid "Menu"
msgstr ""
-#: TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION
-msgid "Pratos"
-msgstr ""
-
#: TFMMEAL.BTADD.CAPTION
msgctxt "TFMMEAL.BTADD.CAPTION"
-msgid "Adicionar"
+msgid "Add"
msgstr ""
#: TFMMEAL.BTADDANDCLOSE.CAPTION
-msgid "Adicionar e Fechar"
+msgid "Add and Close"
msgstr ""
#: TFMMEAL.BTADDDISH.CAPTION
msgctxt "TFMMEAL.BTADDDISH.CAPTION"
-msgid "Adicionar"
+msgid "Add"
msgstr ""
#: TFMMEAL.BTCLEAR.CAPTION
msgctxt "TFMMEAL.BTCLEAR.CAPTION"
-msgid "Limpar"
+msgid "Clear"
msgstr ""
#: TFMMEAL.BTCLOSE.CAPTION
msgctxt "TFMMEAL.BTCLOSE.CAPTION"
-msgid "Fechar"
+msgid "Close"
msgstr ""
#: TFMMEAL.BTDOWN.CAPTION
-msgid "Abaixo"
+msgctxt "TFMMEAL.BTDOWN.CAPTION"
+msgid "Down"
msgstr ""
#: TFMMEAL.BTREMOVE.CAPTION
-msgid "Remover"
+msgctxt "TFMMEAL.BTREMOVE.CAPTION"
+msgid "Remove"
msgstr ""
#: TFMMEAL.BTUP.CAPTION
-msgid "Acima"
+msgctxt "TFMMEAL.BTUP.CAPTION"
+msgid "Up"
msgstr ""
#: TFMMEAL.CAPTION
-msgid "fmMeal"
+msgctxt "TFMMEAL.CAPTION"
+msgid "Meal"
msgstr ""
#: TFMMEAL.DEDATE.CANCELCAPTION
-msgid "Cancelar"
+msgid "Cancel"
msgstr ""
#: TFMMEAL.DEDATE.DIALOGTITLE
-msgid "Escolha a data"
+msgid "Choose the date"
msgstr ""
#: TFMMEAL.DEDATE.OKCAPTION
@@ -111,21 +113,34 @@
msgstr ""
#: TFMMEAL.GBMEAL.CAPTION
-msgid "Refeição"
+msgctxt "TFMMEAL.GBMEAL.CAPTION"
+msgid "Meal"
msgstr ""
+#: TFMMEAL.LBDATE.CAPTION
+msgid "Date:"
+msgstr ""
+
#: TFMMEAL.LBDISH.CAPTION
-msgid "Prato:"
+msgid "Dish:"
msgstr ""
#: TFMMEAL.LBLMEAL.CAPTION
-msgid "Refeição:"
+msgid "Meal:"
msgstr ""
#: TFMMEAL.LBTYPE.CAPTION
-msgid "Tipo:"
+msgid "Dish Type:"
msgstr ""
+#: u_consts.sdate
+msgid "Date"
+msgstr ""
+
+#: u_consts.sdishes
+msgid "Dishes"
+msgstr ""
+
#: u_consts.serror
msgid "Error!!!"
msgstr ""
Modified: trunk/lang/gotisso.pt_BR.po
===================================================================
--- trunk/lang/gotisso.pt_BR.po 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/lang/gotisso.pt_BR.po 2009-12-10 02:41:25 UTC (rev 19)
@@ -13,46 +13,56 @@
"X-Poedit-SourceCharset: utf-8\n"
#: TFMINGREDIENTS.BTCLOSE.CAPTION
+#| msgid "Fechar"
msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
-msgid "Fechar"
+msgid "Close"
msgstr "Fechar"
#: TFMINGREDIENTS.BTPRINT.CAPTION
+#| msgid "Imprimir..."
msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
-msgid "Imprimir..."
+msgid "Print..."
msgstr "Imprimir..."
#: TFMINGREDIENTS.CAPTION
-msgid "Ingredientes"
+#| msgid "Ingredientes"
+msgid "Ingredients"
msgstr "Ingredientes"
#: TFMMAIN.BTCLEAR.CAPTION
+#| msgid "Limpar"
msgctxt "TFMMAIN.BTCLEAR.CAPTION"
-msgid "Limpar"
+msgid "Clear"
msgstr "Limpar"
#: TFMMAIN.BTDOWN.CAPTION
+msgctxt "TFMMAIN.BTDOWN.CAPTION"
msgid "Down"
msgstr "Para baixo"
#: TFMMAIN.BTINGREDIENTS.CAPTION
-msgid "Lista de Ingredientes..."
+#| msgid "Lista de Ingredientes..."
+msgid "Ingredients List..."
msgstr "Lista de Ingredientes..."
#: TFMMAIN.BTNEW.CAPTION
-msgid "Nova..."
+#| msgid "Nova..."
+msgid "New..."
msgstr "Nova..."
#: TFMMAIN.BTPRINT.CAPTION
+#| msgid "Imprimir..."
msgctxt "TFMMAIN.BTPRINT.CAPTION"
-msgid "Imprimir..."
+msgid "Print..."
msgstr "Imprimir..."
#: TFMMAIN.BTREMOVE.CAPTION
+msgctxt "TFMMAIN.BTREMOVE.CAPTION"
msgid "Remove"
msgstr "Remover"
#: TFMMAIN.BTUP.CAPTION
+msgctxt "TFMMAIN.BTUP.CAPTION"
msgid "Up"
msgstr "Para cima"
@@ -61,60 +71,72 @@
msgstr "Principal"
#: TFMMAIN.GBMENU.CAPTION
+#| msgid "Cardápio"
msgctxt "TFMMAIN.GBMENU.CAPTION"
-msgid "Cardápio"
+msgid "Menu"
msgstr "Cardápio"
-#: TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION
-msgid "Pratos"
-msgstr "Pratos"
-
#: TFMMEAL.BTADD.CAPTION
+#| msgid "Adicionar"
msgctxt "TFMMEAL.BTADD.CAPTION"
-msgid "Adicionar"
+msgid "Add"
msgstr "Adicionar"
#: TFMMEAL.BTADDANDCLOSE.CAPTION
-msgid "Adicionar e Fechar"
+#| msgid "Adicionar e Fechar"
+msgid "Add and Close"
msgstr "Adicionar e Fechar"
#: TFMMEAL.BTADDDISH.CAPTION
+#| msgid "Adicionar"
msgctxt "TFMMEAL.BTADDDISH.CAPTION"
-msgid "Adicionar"
+msgid "Add"
msgstr "Adicionar"
#: TFMMEAL.BTCLEAR.CAPTION
+#| msgid "Limpar"
msgctxt "TFMMEAL.BTCLEAR.CAPTION"
-msgid "Limpar"
+msgid "Clear"
msgstr "Limpar"
#: TFMMEAL.BTCLOSE.CAPTION
+#| msgid "Fechar"
msgctxt "TFMMEAL.BTCLOSE.CAPTION"
-msgid "Fechar"
+msgid "Close"
msgstr "Fechar"
#: TFMMEAL.BTDOWN.CAPTION
-msgid "Abaixo"
+#| msgid "Abaixo"
+msgctxt "TFMMEAL.BTDOWN.CAPTION"
+msgid "Down"
msgstr "Para baixo"
#: TFMMEAL.BTREMOVE.CAPTION
-msgid "Remover"
+#| msgid "Remover"
+msgctxt "TFMMEAL.BTREMOVE.CAPTION"
+msgid "Remove"
msgstr "Remover"
#: TFMMEAL.BTUP.CAPTION
-msgid "Acima"
-msgstr "Acima"
+#| msgid "Acima"
+msgctxt "TFMMEAL.BTUP.CAPTION"
+msgid "Up"
+msgstr "Para cima"
#: TFMMEAL.CAPTION
-msgid "fmMeal"
+#| msgid "Refeição"
+msgctxt "TFMMEAL.CAPTION"
+msgid "Meal"
msgstr "Refeição"
#: TFMMEAL.DEDATE.CANCELCAPTION
-msgid "Cancelar"
+#| msgid "Cancelar"
+msgid "Cancel"
msgstr "Cancelar"
#: TFMMEAL.DEDATE.DIALOGTITLE
-msgid "Escolha a data"
+#| msgid "Escolha a data"
+msgid "Choose the date"
msgstr "Escolha a data"
#: TFMMEAL.DEDATE.OKCAPTION
@@ -122,21 +144,41 @@
msgstr "Aceitar"
#: TFMMEAL.GBMEAL.CAPTION
-msgid "Refeição"
+#| msgid "Refeição"
+msgctxt "TFMMEAL.GBMEAL.CAPTION"
+msgid "Meal"
msgstr "Refeição"
+#: TFMMEAL.LBDATE.CAPTION
+#| msgid "Data:"
+msgid "Date:"
+msgstr "Data:"
+
#: TFMMEAL.LBDISH.CAPTION
-msgid "Prato:"
+#| msgid "Prato:"
+msgid "Dish:"
msgstr "Prato:"
#: TFMMEAL.LBLMEAL.CAPTION
-msgid "Refeição:"
+#| msgid "Refeição:"
+msgid "Meal:"
msgstr "Refeição:"
#: TFMMEAL.LBTYPE.CAPTION
-msgid "Tipo:"
+#| msgid "Tipo:"
+msgid "Dish Type:"
msgstr "Tipo:"
+#: u_consts.sdate
+#| msgid "Data"
+msgid "Date"
+msgstr "Data"
+
+#: u_consts.sdishes
+#| msgid "Pratos"
+msgid "Dishes"
+msgstr "Pratos"
+
#: u_consts.serror
msgid "Error!!!"
msgstr "Erro!!!"
Added: trunk/output/languages/gotisso.en.mo
===================================================================
(Binary files differ)
Property changes on: trunk/output/languages/gotisso.en.mo
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/output/languages/gotisso.pt_BR.mo
===================================================================
(Binary files differ)
Property changes on: trunk/output/languages/gotisso.pt_BR.mo
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/output/languages/lclstrconsts.pt_BR.mo
===================================================================
(Binary files differ)
Property changes on: trunk/output/languages/lclstrconsts.pt_BR.mo
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/u_classes.pas
===================================================================
--- trunk/u_classes.pas 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_classes.pas 2009-12-10 02:41:25 UTC (rev 19)
@@ -30,6 +30,8 @@
type
+// TODO: maybe these classes can be changed to TCollection and TCollectionItem descendents
+
{ TDish }
TDish = class(TPersistent)
Modified: trunk/u_consts.pas
===================================================================
--- trunk/u_consts.pas 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_consts.pas 2009-12-10 02:41:25 UTC (rev 19)
@@ -32,6 +32,8 @@
resourcestring
sError = 'Error!!!';
+ sDate = 'Date';
+ sDishes = 'Dishes';
implementation
Modified: trunk/u_ingredients.lfm
===================================================================
--- trunk/u_ingredients.lfm 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_ingredients.lfm 2009-12-10 02:41:25 UTC (rev 19)
@@ -1,9 +1,9 @@
object fmIngredients: TfmIngredients
- Left = 400
+ Left = 392
Height = 300
- Top = 245
+ Top = 253
Width = 400
- Caption = 'Ingredientes'
+ Caption = 'Ingredients'
ClientHeight = 300
ClientWidth = 400
LCLVersion = '0.9.28.2'
@@ -20,7 +20,7 @@
Height = 25
Top = 248
Width = 75
- Caption = 'Imprimir...'
+ Caption = 'Print...'
Default = True
OnClick = btPrintClick
TabOrder = 1
@@ -31,7 +31,7 @@
Top = 252
Width = 75
Cancel = True
- Caption = 'Fechar'
+ Caption = 'Close'
OnClick = btCloseClick
TabOrder = 2
end
Modified: trunk/u_ingredients.lrt
===================================================================
--- trunk/u_ingredients.lrt 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_ingredients.lrt 2009-12-10 02:41:25 UTC (rev 19)
@@ -1,3 +1,3 @@
-TFMINGREDIENTS.CAPTION=Ingredientes
-TFMINGREDIENTS.BTPRINT.CAPTION=Imprimir...
-TFMINGREDIENTS.BTCLOSE.CAPTION=Fechar
+TFMINGREDIENTS.CAPTION=Ingredients
+TFMINGREDIENTS.BTPRINT.CAPTION=Print...
+TFMINGREDIENTS.BTCLOSE.CAPTION=Close
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_main.lfm 2009-12-10 02:41:25 UTC (rev 19)
@@ -1,11 +1,11 @@
object fmMain: TfmMain
- Left = 332
- Height = 459
- Top = 178
- Width = 576
+ Left = 315
+ Height = 462
+ Top = 202
+ Width = 819
Caption = 'fmMain'
- ClientHeight = 459
- ClientWidth = 576
+ ClientHeight = 462
+ ClientWidth = 819
OnCreate = FormCreate
OnDestroy = FormDestroy
OnShow = FormShow
@@ -14,70 +14,63 @@
LCLVersion = '0.9.28.2'
object gbMenu: TGroupBox
Left = 24
- Height = 361
- Top = 24
- Width = 527
- Caption = 'Cardápio'
- ClientHeight = 343
- ClientWidth = 523
+ Height = 408
+ Top = 32
+ Width = 776
+ Caption = 'Menu'
+ ClientHeight = 390
+ ClientWidth = 772
TabOrder = 0
object sgMenu: TStringGrid
Left = 21
- Height = 260
+ Height = 312
Top = 17
- Width = 385
- Anchors = [akTop, akLeft, akBottom]
+ Width = 641
+ Anchors = [akTop, akLeft, akRight, akBottom]
ColCount = 2
- Columns = <
- item
- Title.Caption = 'Data'
- end
- item
- Title.Caption = 'Pratos'
- Width = 310
- end>
FixedCols = 0
Options = [goFixedVertLine, goFixedHorzLine, goVertLine, goHorzLine, goRangeSelect, goColSizing, goRowSelect, goDblClickAutoSize, goSmoothScroll]
RowCount = 1
TabOrder = 0
+ TitleStyle = tsStandard
OnClick = sgMenuClick
- ColWidths = (
- 64
- 310
- )
end
object btNew: TButton
- Left = 413
+ Left = 686
Height = 25
- Top = 17
+ Top = 16
Width = 75
- Caption = 'Nova...'
+ Anchors = [akTop, akRight]
+ Caption = 'New...'
OnClick = btNewClick
TabOrder = 1
end
object btDown: TButton
- Left = 413
+ Left = 686
Height = 25
Top = 96
Width = 75
+ Anchors = [akTop, akRight]
Caption = 'Down'
OnClick = btDownClick
TabOrder = 2
end
object btClear: TButton
- Left = 413
+ Left = 686
Height = 25
- Top = 248
+ Top = 184
Width = 75
- Caption = 'Limpar'
+ Anchors = [akTop, akRight]
+ Caption = 'Clear'
OnClick = btClearClick
TabOrder = 3
end
object btUp: TButton
- Left = 414
+ Left = 686
Height = 25
Top = 64
Width = 75
+ Anchors = [akTop, akRight]
Caption = 'Up'
OnClick = btUpClick
TabOrder = 4
@@ -85,28 +78,29 @@
object btPrint: TButton
Left = 21
Height = 25
- Top = 297
+ Top = 352
Width = 75
Anchors = [akLeft, akBottom]
- Caption = 'Imprimir...'
+ Caption = 'Print...'
OnClick = btPrintClick
TabOrder = 5
end
object btIngredients: TButton
- Left = 134
+ Left = 118
Height = 25
- Top = 296
+ Top = 352
Width = 154
Anchors = [akLeft, akBottom]
- Caption = 'Lista de Ingredientes...'
+ Caption = 'Ingredients List...'
OnClick = btIngredientsClick
TabOrder = 6
end
object btRemove: TButton
- Left = 413
+ Left = 686
Height = 25
Top = 128
Width = 75
+ Anchors = [akTop, akRight]
Caption = 'Remove'
OnClick = btRemoveClick
TabOrder = 7
Modified: trunk/u_main.lrt
===================================================================
--- trunk/u_main.lrt 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_main.lrt 2009-12-10 02:41:25 UTC (rev 19)
@@ -1,11 +1,9 @@
TFMMAIN.CAPTION=fmMain
-TFMMAIN.GBMENU.CAPTION=Cardápio
-TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION=Data
-TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION=Pratos
-TFMMAIN.BTNEW.CAPTION=Nova...
+TFMMAIN.GBMENU.CAPTION=Menu
+TFMMAIN.BTNEW.CAPTION=New...
TFMMAIN.BTDOWN.CAPTION=Down
-TFMMAIN.BTCLEAR.CAPTION=Limpar
+TFMMAIN.BTCLEAR.CAPTION=Clear
TFMMAIN.BTUP.CAPTION=Up
-TFMMAIN.BTPRINT.CAPTION=Imprimir...
-TFMMAIN.BTINGREDIENTS.CAPTION=Lista de Ingredientes...
+TFMMAIN.BTPRINT.CAPTION=Print...
+TFMMAIN.BTINGREDIENTS.CAPTION=Ingredients List...
TFMMAIN.BTREMOVE.CAPTION=Remove
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_main.pas 2009-12-10 02:41:25 UTC (rev 19)
@@ -26,7 +26,7 @@
uses
Classes, SysUtils, FileUtil, LResources, Forms, Controls, Graphics, Dialogs,
- StdCtrls, EditBtn, ExtDlgs, Grids, PrintersDlgs;
+ StdCtrls, EditBtn, ExtDlgs, Grids, PrintersDlgs, DefaultTranslator;
type
@@ -103,6 +103,8 @@
procedure TfmMain.FormShow(Sender: TObject);
begin
Caption:= Application.Title;
+ sgMenu.Cells[0,0]:= sDate;
+ sgMenu.Cells[1,0]:= sDishes;
FillMenuGrid;
end;
Modified: trunk/u_meal.lfm
===================================================================
--- trunk/u_meal.lfm 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_meal.lfm 2009-12-10 02:41:25 UTC (rev 19)
@@ -1,9 +1,9 @@
object fmMeal: TfmMeal
- Left = 354
+ Left = 362
Height = 333
- Top = 230
+ Top = 246
Width = 561
- Caption = 'fmMeal'
+ Caption = 'Meal'
ClientHeight = 333
ClientWidth = 561
OnCreate = FormCreate
@@ -15,7 +15,7 @@
Top = 16
Width = 520
Anchors = [akTop, akLeft, akRight, akBottom]
- Caption = 'Refeição'
+ Caption = 'Meal'
ClientHeight = 222
ClientWidth = 516
TabOrder = 0
@@ -23,8 +23,8 @@
Left = 30
Height = 14
Top = 23
- Width = 25
- Caption = 'Tipo:'
+ Width = 52
+ Caption = 'Dish Type:'
FocusControl = cbType
ParentColor = False
end
@@ -32,19 +32,27 @@
Left = 30
Height = 14
Top = 72
- Width = 31
- Caption = 'Prato:'
+ Width = 25
+ Caption = 'Dish:'
FocusControl = cbDish
ParentColor = False
end
object lblMeal: TLabel
Left = 238
Height = 14
- Top = 24
- Width = 47
- Caption = 'Refeição:'
+ Top = 72
+ Width = 27
+ Caption = 'Meal:'
ParentColor = False
end
+ object lbDate: TLabel
+ Left = 242
+ Height = 14
+ Top = 21
+ Width = 28
+ Caption = 'Date:'
+ ParentColor = False
+ end
object cbType: TComboBox
Left = 30
Height = 21
@@ -58,12 +66,12 @@
object deDate: TDateEdit
Left = 238
Height = 21
- Top = 176
- Width = 128
- DialogTitle = 'Escolha a data'
+ Top = 40
+ Width = 152
+ DialogTitle = 'Choose the date'
CalendarDisplaySettings = [dsShowHeadings, dsShowDayNames]
OKCaption = 'OK'
- CancelCaption = 'Cancelar'
+ CancelCaption = 'Cancel'
DefaultToday = True
DateOrder = doDMY
ButtonWidth = 23
@@ -120,14 +128,14 @@
Height = 25
Top = 127
Width = 75
- Caption = 'Adicionar'
+ Caption = 'Add'
OnClick = btAddDishClick
TabOrder = 3
end
object lbMeal: TListBox
Left = 238
Height = 112
- Top = 40
+ Top = 88
Width = 152
ItemHeight = 0
MultiSelect = True
@@ -137,9 +145,9 @@
object btDown: TButton
Left = 414
Height = 25
- Top = 69
+ Top = 117
Width = 75
- Caption = 'Abaixo'
+ Caption = 'Down'
Enabled = False
OnClick = btDownClick
TabOrder = 5
@@ -147,9 +155,9 @@
object btUp: TButton
Left = 414
Height = 25
- Top = 40
+ Top = 88
Width = 75
- Caption = 'Acima'
+ Caption = 'Up'
Enabled = False
OnClick = btUpClick
TabOrder = 6
@@ -157,9 +165,9 @@
object btRemove: TButton
Left = 414
Height = 25
- Top = 96
+ Top = 144
Width = 75
- Caption = 'Remover'
+ Caption = 'Remove'
Enabled = False
OnClick = btRemoveClick
TabOrder = 7
@@ -167,9 +175,9 @@
object btClear: TButton
Left = 414
Height = 25
- Top = 127
+ Top = 175
Width = 75
- Caption = 'Limpar'
+ Caption = 'Clear'
Enabled = False
OnClick = btClearClick
TabOrder = 8
@@ -180,7 +188,7 @@
Height = 25
Top = 280
Width = 75
- Caption = 'Adicionar'
+ Caption = 'Add'
Default = True
OnClick = btAddClick
TabOrder = 1
@@ -190,7 +198,7 @@
Height = 25
Top = 280
Width = 107
- Caption = 'Adicionar e Fechar'
+ Caption = 'Add and Close'
OnClick = btAddAndCloseClick
TabOrder = 2
end
@@ -200,7 +208,7 @@
Top = 280
Width = 75
Cancel = True
- Caption = 'Fechar'
+ Caption = 'Close'
OnClick = btCloseClick
TabOrder = 3
end
Modified: trunk/u_meal.lrt
===================================================================
--- trunk/u_meal.lrt 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_meal.lrt 2009-12-10 02:41:25 UTC (rev 19)
@@ -1,16 +1,17 @@
-TFMMEAL.CAPTION=fmMeal
-TFMMEAL.GBMEAL.CAPTION=Refeição
-TFMMEAL.LBTYPE.CAPTION=Tipo:
-TFMMEAL.LBDISH.CAPTION=Prato:
-TFMMEAL.LBLMEAL.CAPTION=Refeição:
-TFMMEAL.DEDATE.DIALOGTITLE=Escolha a data
+TFMMEAL.CAPTION=Meal
+TFMMEAL.GBMEAL.CAPTION=Meal
+TFMMEAL.LBTYPE.CAPTION=Dish Type:
+TFMMEAL.LBDISH.CAPTION=Dish:
+TFMMEAL.LBLMEAL.CAPTION=Meal:
+TFMMEAL.LBDATE.CAPTION=Date:
+TFMMEAL.DEDATE.DIALOGTITLE=Choose the date
TFMMEAL.DEDATE.OKCAPTION=OK
-TFMMEAL.DEDATE.CANCELCAPTION=Cancelar
-TFMMEAL.BTADDDISH.CAPTION=Adicionar
-TFMMEAL.BTDOWN.CAPTION=Abaixo
-TFMMEAL.BTUP.CAPTION=Acima
-TFMMEAL.BTREMOVE.CAPTION=Remover
-TFMMEAL.BTCLEAR.CAPTION=Limpar
-TFMMEAL.BTADD.CAPTION=Adicionar
-TFMMEAL.BTADDANDCLOSE.CAPTION=Adicionar e Fechar
-TFMMEAL.BTCLOSE.CAPTION=Fechar
+TFMMEAL.DEDATE.CANCELCAPTION=Cancel
+TFMMEAL.BTADDDISH.CAPTION=Add
+TFMMEAL.BTDOWN.CAPTION=Down
+TFMMEAL.BTUP.CAPTION=Up
+TFMMEAL.BTREMOVE.CAPTION=Remove
+TFMMEAL.BTCLEAR.CAPTION=Clear
+TFMMEAL.BTADD.CAPTION=Add
+TFMMEAL.BTADDANDCLOSE.CAPTION=Add and Close
+TFMMEAL.BTCLOSE.CAPTION=Close
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-10 01:12:06 UTC (rev 18)
+++ trunk/u_meal.pas 2009-12-10 02:41:25 UTC (rev 19)
@@ -45,6 +45,7 @@
cbType: TComboBox;
deDate: TDateEdit;
gbMeal: TGroupBox;
+ lbDate: TLabel;
lblMeal: TLabel;
lbDish: TLabel;
lbMeal: TListBox;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-10 01:12:17
|
Revision: 18
http://gotisso.svn.sourceforge.net/gotisso/?rev=18&view=rev
Author: jmvaz
Date: 2009-12-10 01:12:06 +0000 (Thu, 10 Dec 2009)
Log Message:
-----------
localization tests
Added Paths:
-----------
trunk/output/languages/en/
trunk/output/languages/pt_BR/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-10 01:09:01
|
Revision: 17
http://gotisso.svn.sourceforge.net/gotisso/?rev=17&view=rev
Author: jmvaz
Date: 2009-12-10 01:08:54 +0000 (Thu, 10 Dec 2009)
Log Message:
-----------
localization tests
Added Paths:
-----------
trunk/lang/gotisso.en.po
trunk/lang/gotisso.pt_BR.po
trunk/output/languages/
Added: trunk/lang/gotisso.en.po
===================================================================
--- trunk/lang/gotisso.en.po (rev 0)
+++ trunk/lang/gotisso.en.po 2009-12-10 01:08:54 UTC (rev 17)
@@ -0,0 +1,140 @@
+msgid ""
+msgstr ""
+"Content-Type: text/plain; charset=UTF-8\n"
+"Project-Id-Version: \n"
+"POT-Creation-Date: \n"
+"PO-Revision-Date: \n"
+"Last-Translator: João Marcelo S. Vaz <jm...@gm...>\n"
+"Language-Team: \n"
+"MIME-Version: 1.0\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: TFMINGREDIENTS.BTCLOSE.CAPTION
+msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
+msgid "Fechar"
+msgstr "Close"
+
+#: TFMINGREDIENTS.BTPRINT.CAPTION
+msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
+msgid "Imprimir..."
+msgstr "Print..."
+
+#: TFMINGREDIENTS.CAPTION
+msgid "Ingredientes"
+msgstr "Ingredients"
+
+#: TFMMAIN.BTCLEAR.CAPTION
+msgctxt "TFMMAIN.BTCLEAR.CAPTION"
+msgid "Limpar"
+msgstr "Clear"
+
+#: TFMMAIN.BTDOWN.CAPTION
+msgid "Down"
+msgstr "Down"
+
+#: TFMMAIN.BTINGREDIENTS.CAPTION
+msgid "Lista de Ingredientes..."
+msgstr "Ingredients List..."
+
+#: TFMMAIN.BTNEW.CAPTION
+msgid "Nova..."
+msgstr "New..."
+
+#: TFMMAIN.BTPRINT.CAPTION
+msgctxt "TFMMAIN.BTPRINT.CAPTION"
+msgid "Imprimir..."
+msgstr "Print..."
+
+#: TFMMAIN.BTREMOVE.CAPTION
+msgid "Remove"
+msgstr "Remove"
+
+#: TFMMAIN.BTUP.CAPTION
+msgid "Up"
+msgstr "Up"
+
+#: TFMMAIN.CAPTION
+msgid "fmMain"
+msgstr "Main"
+
+#: TFMMAIN.GBMENU.CAPTION
+msgctxt "TFMMAIN.GBMENU.CAPTION"
+msgid "Cardápio"
+msgstr "Menu"
+
+#: TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION
+msgid "Pratos"
+msgstr "Dishes"
+
+#: TFMMEAL.BTADD.CAPTION
+msgctxt "TFMMEAL.BTADD.CAPTION"
+msgid "Adicionar"
+msgstr "Add"
+
+#: TFMMEAL.BTADDANDCLOSE.CAPTION
+msgid "Adicionar e Fechar"
+msgstr "Add and Close"
+
+#: TFMMEAL.BTADDDISH.CAPTION
+msgctxt "TFMMEAL.BTADDDISH.CAPTION"
+msgid "Adicionar"
+msgstr "Add"
+
+#: TFMMEAL.BTCLEAR.CAPTION
+msgctxt "TFMMEAL.BTCLEAR.CAPTION"
+msgid "Limpar"
+msgstr "Clear"
+
+#: TFMMEAL.BTCLOSE.CAPTION
+msgctxt "TFMMEAL.BTCLOSE.CAPTION"
+msgid "Fechar"
+msgstr "Close"
+
+#: TFMMEAL.BTDOWN.CAPTION
+msgid "Abaixo"
+msgstr "Down"
+
+#: TFMMEAL.BTREMOVE.CAPTION
+msgid "Remover"
+msgstr "Remove"
+
+#: TFMMEAL.BTUP.CAPTION
+msgid "Acima"
+msgstr "Up"
+
+#: TFMMEAL.CAPTION
+msgid "fmMeal"
+msgstr "Meal"
+
+#: TFMMEAL.DEDATE.CANCELCAPTION
+msgid "Cancelar"
+msgstr "Cancel"
+
+#: TFMMEAL.DEDATE.DIALOGTITLE
+msgid "Escolha a data"
+msgstr "Choose the Date"
+
+#: TFMMEAL.DEDATE.OKCAPTION
+msgid "OK"
+msgstr "OK"
+
+#: TFMMEAL.GBMEAL.CAPTION
+msgid "Refeição"
+msgstr "Meal"
+
+#: TFMMEAL.LBDISH.CAPTION
+msgid "Prato:"
+msgstr "Dish:"
+
+#: TFMMEAL.LBLMEAL.CAPTION
+msgid "Refeição:"
+msgstr "Meal:"
+
+#: TFMMEAL.LBTYPE.CAPTION
+msgid "Tipo:"
+msgstr "Dish Type:"
+
+#: u_consts.serror
+msgid "Error!!!"
+msgstr "Error!!!"
+
Added: trunk/lang/gotisso.pt_BR.po
===================================================================
--- trunk/lang/gotisso.pt_BR.po (rev 0)
+++ trunk/lang/gotisso.pt_BR.po 2009-12-10 01:08:54 UTC (rev 17)
@@ -0,0 +1,143 @@
+msgid ""
+msgstr ""
+"Content-Type: text/plain; charset=UTF-8\n"
+"Project-Id-Version: Gotisso\n"
+"POT-Creation-Date: \n"
+"PO-Revision-Date: \n"
+"Last-Translator: João Marcelo S. Vaz <jm...@gm...>\n"
+"Language-Team: João Marcelo S. Vaz\n"
+"MIME-Version: 1.0\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-Language: Portuguese\n"
+"X-Poedit-Country: BRAZIL\n"
+"X-Poedit-SourceCharset: utf-8\n"
+
+#: TFMINGREDIENTS.BTCLOSE.CAPTION
+msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
+msgid "Fechar"
+msgstr "Fechar"
+
+#: TFMINGREDIENTS.BTPRINT.CAPTION
+msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
+msgid "Imprimir..."
+msgstr "Imprimir..."
+
+#: TFMINGREDIENTS.CAPTION
+msgid "Ingredientes"
+msgstr "Ingredientes"
+
+#: TFMMAIN.BTCLEAR.CAPTION
+msgctxt "TFMMAIN.BTCLEAR.CAPTION"
+msgid "Limpar"
+msgstr "Limpar"
+
+#: TFMMAIN.BTDOWN.CAPTION
+msgid "Down"
+msgstr "Para baixo"
+
+#: TFMMAIN.BTINGREDIENTS.CAPTION
+msgid "Lista de Ingredientes..."
+msgstr "Lista de Ingredientes..."
+
+#: TFMMAIN.BTNEW.CAPTION
+msgid "Nova..."
+msgstr "Nova..."
+
+#: TFMMAIN.BTPRINT.CAPTION
+msgctxt "TFMMAIN.BTPRINT.CAPTION"
+msgid "Imprimir..."
+msgstr "Imprimir..."
+
+#: TFMMAIN.BTREMOVE.CAPTION
+msgid "Remove"
+msgstr "Remover"
+
+#: TFMMAIN.BTUP.CAPTION
+msgid "Up"
+msgstr "Para cima"
+
+#: TFMMAIN.CAPTION
+msgid "fmMain"
+msgstr "Principal"
+
+#: TFMMAIN.GBMENU.CAPTION
+msgctxt "TFMMAIN.GBMENU.CAPTION"
+msgid "Cardápio"
+msgstr "Cardápio"
+
+#: TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION
+msgid "Pratos"
+msgstr "Pratos"
+
+#: TFMMEAL.BTADD.CAPTION
+msgctxt "TFMMEAL.BTADD.CAPTION"
+msgid "Adicionar"
+msgstr "Adicionar"
+
+#: TFMMEAL.BTADDANDCLOSE.CAPTION
+msgid "Adicionar e Fechar"
+msgstr "Adicionar e Fechar"
+
+#: TFMMEAL.BTADDDISH.CAPTION
+msgctxt "TFMMEAL.BTADDDISH.CAPTION"
+msgid "Adicionar"
+msgstr "Adicionar"
+
+#: TFMMEAL.BTCLEAR.CAPTION
+msgctxt "TFMMEAL.BTCLEAR.CAPTION"
+msgid "Limpar"
+msgstr "Limpar"
+
+#: TFMMEAL.BTCLOSE.CAPTION
+msgctxt "TFMMEAL.BTCLOSE.CAPTION"
+msgid "Fechar"
+msgstr "Fechar"
+
+#: TFMMEAL.BTDOWN.CAPTION
+msgid "Abaixo"
+msgstr "Para baixo"
+
+#: TFMMEAL.BTREMOVE.CAPTION
+msgid "Remover"
+msgstr "Remover"
+
+#: TFMMEAL.BTUP.CAPTION
+msgid "Acima"
+msgstr "Acima"
+
+#: TFMMEAL.CAPTION
+msgid "fmMeal"
+msgstr "Refeição"
+
+#: TFMMEAL.DEDATE.CANCELCAPTION
+msgid "Cancelar"
+msgstr "Cancelar"
+
+#: TFMMEAL.DEDATE.DIALOGTITLE
+msgid "Escolha a data"
+msgstr "Escolha a data"
+
+#: TFMMEAL.DEDATE.OKCAPTION
+msgid "OK"
+msgstr "Aceitar"
+
+#: TFMMEAL.GBMEAL.CAPTION
+msgid "Refeição"
+msgstr "Refeição"
+
+#: TFMMEAL.LBDISH.CAPTION
+msgid "Prato:"
+msgstr "Prato:"
+
+#: TFMMEAL.LBLMEAL.CAPTION
+msgid "Refeição:"
+msgstr "Refeição:"
+
+#: TFMMEAL.LBTYPE.CAPTION
+msgid "Tipo:"
+msgstr "Tipo:"
+
+#: u_consts.serror
+msgid "Error!!!"
+msgstr "Erro!!!"
+
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-09 01:42:21
|
Revision: 16
http://gotisso.svn.sourceforge.net/gotisso/?rev=16&view=rev
Author: jmvaz
Date: 2009-12-09 01:42:12 +0000 (Wed, 09 Dec 2009)
Log Message:
-----------
created TMenuPlan class on u_classes.pas and used it at u_main.pas and u_meal.pas.
minor changes: changed last component name form Portuguese to English; changed forms creation from static to dynamic.
Modified Paths:
--------------
trunk/gotisso.lpr
trunk/lang/gotisso.po
trunk/u_classes.pas
trunk/u_main.lfm
trunk/u_main.lrt
trunk/u_main.pas
trunk/u_meal.pas
Modified: trunk/gotisso.lpr
===================================================================
--- trunk/gotisso.lpr 2009-12-07 14:22:38 UTC (rev 15)
+++ trunk/gotisso.lpr 2009-12-09 01:42:12 UTC (rev 16)
@@ -30,7 +30,7 @@
Interfaces, // this includes the LCL widgetset
Forms
{ you can add units after this },
- u_main, Printer4Lazarus, u_ingredients, u_consts, u_classes, u_meal;
+ Printer4Lazarus, u_main, u_meal, u_ingredients, u_classes, u_consts;
{$IFDEF WINDOWS}{$R gotisso.rc}{$ENDIF}
@@ -38,8 +38,6 @@
Application.Title:= sAppTitle;
Application.Initialize;
Application.CreateForm(TfmMain, fmMain);
- Application.CreateForm(TfmMeal, fmMeal);
- Application.CreateForm(TfmIngredients, fmIngredients);
Application.Run;
end.
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2009-12-07 14:22:38 UTC (rev 15)
+++ trunk/lang/gotisso.po 2009-12-09 01:42:12 UTC (rev 16)
@@ -54,7 +54,7 @@
msgid "Cardápio"
msgstr ""
-#: TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION
+#: TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION
msgid "Pratos"
msgstr ""
Modified: trunk/u_classes.pas
===================================================================
--- trunk/u_classes.pas 2009-12-07 14:22:38 UTC (rev 15)
+++ trunk/u_classes.pas 2009-12-09 01:42:12 UTC (rev 16)
@@ -107,8 +107,29 @@
property Dishes: TDishes read fDishes write SetDishes;
end;
+
+ { TMenuPlan }
+
+ TMenuPlan = class
+ private
+ fList: TStringList;
+ function GetCount: Integer;
+ function GetMeal(Index: Integer): TMeal;
+ protected
+
+ public
+ constructor Create;
+ destructor Destroy; override;
+ function AddMeal(AMeal: TMeal): Boolean;
+ procedure Clear;
+ function RemoveMeal(AIndex: Integer): Boolean;
+ property Count: Integer read GetCount;
+ property Meal[Index: Integer]: TMeal read GetMeal;
+ end;
+
var
Dishes: TDishesDB;
+ MenuPlan: TMenuPlan;
implementation
@@ -312,7 +333,12 @@
function TDishesDB.LoadFromFile(AFileName: TFileName): Boolean;
begin
+ Result:= False;
+ try
+ except
+ Result:= False;
+ end;
end;
{ TMeal }
@@ -347,6 +373,7 @@
destructor TMeal.Destroy;
begin
+ fDishes.Free;
inherited Destroy;
end;
@@ -371,5 +398,53 @@
Result:= fDishes.RemoveDish(ADish);
end;
+{ TMenuPlan }
+
+function TMenuPlan.GetCount: Integer;
+begin
+ Result:= fList.Count;
+end;
+
+function TMenuPlan.GetMeal(Index: Integer): TMeal;
+begin
+ if ((Index >= 0) and (Index < fList.Count)) then
+ Result:= (fList.Objects[Index] as TMeal);
+end;
+
+constructor TMenuPlan.Create;
+begin
+ inherited Create;
+ fList:= TStringList.Create;
+end;
+
+destructor TMenuPlan.Destroy;
+begin
+ Clear;
+ fList.Free;
+ inherited Destroy;
+end;
+
+function TMenuPlan.AddMeal(AMeal: TMeal): Boolean;
+begin
+ Result:= (fList.AddObject(DateToStr(AMeal.Date),AMeal)>-1);
+end;
+
+procedure TMenuPlan.Clear;
+begin
+ fList.Clear;
+end;
+
+function TMenuPlan.RemoveMeal(AIndex: Integer): Boolean;
+begin
+ try
+ TMeal(fList.Objects[AIndex]).Free;
+ fList.Delete(AIndex);
+ Result:= True;
+ except
+ Result:= False;
+ end;
+
+end;
+
end.
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2009-12-07 14:22:38 UTC (rev 15)
+++ trunk/u_main.lfm 2009-12-09 01:42:12 UTC (rev 16)
@@ -7,6 +7,7 @@
ClientHeight = 459
ClientWidth = 576
OnCreate = FormCreate
+ OnDestroy = FormDestroy
OnShow = FormShow
Position = poScreenCenter
ShowHint = True
@@ -20,7 +21,7 @@
ClientHeight = 343
ClientWidth = 523
TabOrder = 0
- object sgCardapio: TStringGrid
+ object sgMenu: TStringGrid
Left = 21
Height = 260
Top = 17
@@ -36,7 +37,10 @@
Width = 310
end>
FixedCols = 0
+ Options = [goFixedVertLine, goFixedHorzLine, goVertLine, goHorzLine, goRangeSelect, goColSizing, goRowSelect, goDblClickAutoSize, goSmoothScroll]
+ RowCount = 1
TabOrder = 0
+ OnClick = sgMenuClick
ColWidths = (
64
310
@@ -57,6 +61,7 @@
Top = 96
Width = 75
Caption = 'Down'
+ OnClick = btDownClick
TabOrder = 2
end
object btClear: TButton
@@ -65,6 +70,7 @@
Top = 248
Width = 75
Caption = 'Limpar'
+ OnClick = btClearClick
TabOrder = 3
end
object btUp: TButton
@@ -73,6 +79,7 @@
Top = 64
Width = 75
Caption = 'Up'
+ OnClick = btUpClick
TabOrder = 4
end
object btPrint: TButton
@@ -101,6 +108,7 @@
Top = 128
Width = 75
Caption = 'Remove'
+ OnClick = btRemoveClick
TabOrder = 7
end
end
Modified: trunk/u_main.lrt
===================================================================
--- trunk/u_main.lrt 2009-12-07 14:22:38 UTC (rev 15)
+++ trunk/u_main.lrt 2009-12-09 01:42:12 UTC (rev 16)
@@ -1,7 +1,7 @@
TFMMAIN.CAPTION=fmMain
TFMMAIN.GBMENU.CAPTION=Cardápio
-TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION=Data
-TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION=Pratos
+TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION=Data
+TFMMAIN.SGMENU.COLUMNS.TITLE.CAPTION=Pratos
TFMMAIN.BTNEW.CAPTION=Nova...
TFMMAIN.BTDOWN.CAPTION=Down
TFMMAIN.BTCLEAR.CAPTION=Limpar
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-07 14:22:38 UTC (rev 15)
+++ trunk/u_main.pas 2009-12-09 01:42:12 UTC (rev 16)
@@ -42,17 +42,25 @@
btRemove: TButton;
gbMenu: TGroupBox;
PrintDialog: TPrintDialog;
- sgCardapio: TStringGrid;
+ sgMenu: TStringGrid;
+ procedure btClearClick(Sender: TObject);
+ procedure btDownClick(Sender: TObject);
procedure btPrintClick(Sender: TObject);
procedure btIngredientsClick(Sender: TObject);
procedure btNewClick(Sender: TObject);
+ procedure btRemoveClick(Sender: TObject);
+ procedure btUpClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
+ procedure FormDestroy(Sender: TObject);
procedure FormShow(Sender: TObject);
+ procedure sgMenuClick(Sender: TObject);
private
{ private declarations }
public
{ public declarations }
+ procedure UpdateMenu;
+ procedure FillMenuGrid;
end;
var
@@ -67,6 +75,7 @@
procedure TfmMain.FormCreate(Sender: TObject);
begin
Dishes:= TDishesDB.Create;
+ MenuPlan:= TMenuPlan.Create;
@@ -85,17 +94,54 @@
end;
+procedure TfmMain.FormDestroy(Sender: TObject);
+begin
+ MenuPlan.Free;
+ Dishes.Free;
+end;
+
procedure TfmMain.FormShow(Sender: TObject);
begin
Caption:= Application.Title;
+ FillMenuGrid;
end;
+procedure TfmMain.sgMenuClick(Sender: TObject);
+begin
+ UpdateMenu;
+end;
+
+procedure TfmMain.UpdateMenu;
+begin
+// enable or disable the buttons depending on the dish count or dish selected position
+ btUp.Enabled:= ((sgMenu.IsCellSelected[0,sgMenu.Row]) and (not (sgMenu.IsCellSelected[0,1] or sgMenu.IsCellSelected[0,0])));
+ btDown.Enabled:= ((sgMenu.IsCellSelected[0,sgMenu.Row]) and (not sgMenu.IsCellSelected[0,sgMenu.RowCount-1]));
+ btRemove.Enabled:= ((sgMenu.IsCellSelected[0,sgMenu.Row]) and (not sgMenu.IsCellSelected[0,0]));
+ btClear.Enabled:= (sgMenu.RowCount > 1);
+ btPrint.Enabled:= btClear.Enabled;
+ btIngredients.Enabled:= btClear.Enabled;
+end;
+
+procedure TfmMain.FillMenuGrid;
+var
+ i: Integer;
+begin
+ sgMenu.RowCount:= MenuPlan.Count + 1;
+ for i:= 1 to MenuPlan.Count do
+ begin
+ sgMenu.Cells[0,i]:= DateToStr(MenuPlan.Meal[i-1].Date);
+ sgMenu.Cells[1,i]:= MenuPlan.Meal[i-1].Dishes.AllDishes.Text;
+ end;
+ UpdateMenu;
+end;
+
+
procedure TfmMain.btPrintClick(Sender: TObject);
begin
if PrintDialog.Execute then
with TStringGridPrinter.Create do
try
- aStringGrid:= sgCardapio;
+ aStringGrid:= sgMenu;
Title:= Application.Title;
TitleFont.Size:= 12;
TitlePosition:= ppTopMiddle;
@@ -111,16 +157,51 @@
end;
+procedure TfmMain.btDownClick(Sender: TObject);
+begin
+ //TODO: create menu grid down procedure
+ FillMenuGrid;
+end;
+
+procedure TfmMain.btClearClick(Sender: TObject);
+begin
+ MenuPlan.Clear;
+ FillMenuGrid;
+end;
+
procedure TfmMain.btIngredientsClick(Sender: TObject);
begin
- fmIngredients.ShowModal;
+ with TfmIngredients.Create(Application) do
+ try
+ ShowModal;
+ finally
+ Release;
+ end;
end;
procedure TfmMain.btNewClick(Sender: TObject);
begin
- fmMeal.ShowModal;
+ with TfmMeal.Create(Application) do
+ try
+ ShowModal;
+ FillMenuGrid;
+ finally
+ Release;
+ end;
end;
+procedure TfmMain.btRemoveClick(Sender: TObject);
+begin
+ MenuPlan.RemoveMeal(sgMenu.Row-1);
+ FillMenuGrid;
+end;
+
+procedure TfmMain.btUpClick(Sender: TObject);
+begin
+ //TODO: create menu grid up procedure
+ FillMenuGrid;
+end;
+
initialization
{$I u_main.lrs}
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-07 14:22:38 UTC (rev 15)
+++ trunk/u_meal.pas 2009-12-09 01:42:12 UTC (rev 16)
@@ -208,14 +208,15 @@
Meal.AddDish(Dishes.DishByName(lbMeal.Items.Strings[i]));
end;
Meal.Date:= deDate.Date;
-
- //TODO: add to menu object
-
- lbMeal.Clear;
- UpdateMeal;
+ Result:= MenuPlan.AddMeal(Meal);
except
Result:= False;
end;
+ if Result then
+ begin
+ lbMeal.Clear;
+ UpdateMeal;
+ end;
end;
initialization
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-07 14:22:48
|
Revision: 15
http://gotisso.svn.sourceforge.net/gotisso/?rev=15&view=rev
Author: jmvaz
Date: 2009-12-07 14:22:38 +0000 (Mon, 07 Dec 2009)
Log Message:
-----------
Application Title behavior modification (it won't be translated anymore)
Modified Paths:
--------------
trunk/gotisso.lpr
trunk/lang/gotisso.po
trunk/u_consts.pas
trunk/u_main.lfm
trunk/u_main.pas
Modified: trunk/gotisso.lpr
===================================================================
--- trunk/gotisso.lpr 2009-12-07 14:21:18 UTC (rev 14)
+++ trunk/gotisso.lpr 2009-12-07 14:22:38 UTC (rev 15)
@@ -35,7 +35,7 @@
{$IFDEF WINDOWS}{$R gotisso.rc}{$ENDIF}
begin
- Application.Title:= sTitle;
+ Application.Title:= sAppTitle;
Application.Initialize;
Application.CreateForm(TfmMain, fmMain);
Application.CreateForm(TfmMeal, fmMeal);
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2009-12-07 14:21:18 UTC (rev 14)
+++ trunk/lang/gotisso.po 2009-12-07 14:22:38 UTC (rev 15)
@@ -130,7 +130,3 @@
msgid "Error!!!"
msgstr ""
-#: u_consts.stitle
-msgid "Gotisso Meal Planner"
-msgstr ""
-
Modified: trunk/u_consts.pas
===================================================================
--- trunk/u_consts.pas 2009-12-07 14:21:18 UTC (rev 14)
+++ trunk/u_consts.pas 2009-12-07 14:22:38 UTC (rev 15)
@@ -27,8 +27,10 @@
uses
Classes, SysUtils;
+const
+ sAppTitle = 'Gotisso Meal Planner'; // Application Name (as a const as it shouldn't be translated
+
resourcestring
- sTitle = 'Gotisso Meal Planner';
sError = 'Error!!!';
implementation
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2009-12-07 14:21:18 UTC (rev 14)
+++ trunk/u_main.lfm 2009-12-07 14:22:38 UTC (rev 15)
@@ -7,6 +7,7 @@
ClientHeight = 459
ClientWidth = 576
OnCreate = FormCreate
+ OnShow = FormShow
Position = poScreenCenter
ShowHint = True
LCLVersion = '0.9.28.2'
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-07 14:21:18 UTC (rev 14)
+++ trunk/u_main.pas 2009-12-07 14:22:38 UTC (rev 15)
@@ -47,6 +47,7 @@
procedure btIngredientsClick(Sender: TObject);
procedure btNewClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
+ procedure FormShow(Sender: TObject);
private
{ private declarations }
@@ -65,10 +66,10 @@
procedure TfmMain.FormCreate(Sender: TObject);
begin
- Caption:= sTitle;
Dishes:= TDishesDB.Create;
+
// testes temporários
Dishes.AddDish(TDish.Create('Bife a milanesa','carne'));
Dishes.AddDish(TDish.Create('Frango a milanesa','carne'));
@@ -84,13 +85,18 @@
end;
+procedure TfmMain.FormShow(Sender: TObject);
+begin
+ Caption:= Application.Title;
+end;
+
procedure TfmMain.btPrintClick(Sender: TObject);
begin
if PrintDialog.Execute then
with TStringGridPrinter.Create do
try
aStringGrid:= sgCardapio;
- Title:= sTitle;
+ Title:= Application.Title;
TitleFont.Size:= 12;
TitlePosition:= ppTopMiddle;
PageNumPosition:= ppNone;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-07 14:21:26
|
Revision: 14
http://gotisso.svn.sourceforge.net/gotisso/?rev=14&view=rev
Author: jmvaz
Date: 2009-12-07 14:21:18 +0000 (Mon, 07 Dec 2009)
Log Message:
-----------
added some comments
Modified Paths:
--------------
trunk/u_meal.pas
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-06 01:51:56 UTC (rev 13)
+++ trunk/u_meal.pas 2009-12-07 14:21:18 UTC (rev 14)
@@ -109,13 +109,17 @@
if not Add then
ShowMessage(sError)
else
- Close;
+ begin
+ lbMeal.Clear;
+ Close;
+ end;
end;
procedure TfmMeal.btDownClick(Sender: TObject);
var
i: Integer;
begin
+// moving down the selected rows, mantaining then selected
for i:= (lbMeal.Count-2) downto 0 do
if lbMeal.Selected[i] then
begin
@@ -128,18 +132,21 @@
procedure TfmMeal.btCloseClick(Sender: TObject);
begin
+// close the form, after clearing the meal listbox
lbMeal.Clear;
Close;
end;
procedure TfmMeal.btAddDishClick(Sender: TObject);
begin
+// add choosed dish to the meal listbox
lbMeal.Items.Add(cbDish.Items.Strings[cbDish.ItemIndex]);
UpdateMeal;
end;
procedure TfmMeal.btClearClick(Sender: TObject);
begin
+// clear the meal listbox
lbMeal.Clear;
UpdateMeal;
end;
@@ -148,6 +155,7 @@
var
i: Integer;
begin
+//removing the selected rows
for i:= (lbMeal.Count-1) downto 0 do
if lbMeal.Selected[i] then
lbMeal.Items.Delete(i);
@@ -158,6 +166,7 @@
var
i: Integer;
begin
+// moving up the selected rows, mantaining then selected
for i:= 1 to (lbMeal.Count-1) do
if lbMeal.Selected[i] then
begin
@@ -173,8 +182,10 @@
UpdateMeal;
end;
+
procedure TfmMeal.UpdateMeal;
begin
+// enable or disable the buttons depending on the dish count or dish selected position
btUp.Enabled:= ((lbMeal.SelCount > 0) and (not lbMeal.Selected[0]));
btDown.Enabled:= ((lbMeal.SelCount > 0) and (not lbMeal.Selected[lbMeal.Count-1]));
btRemove.Enabled:= (lbMeal.SelCount > 0);
@@ -188,6 +199,7 @@
Meal: TMeal;
i: Integer;
begin
+// add the meal to the menu object
Result:= False;
Meal:= TMeal.Create;
try
@@ -197,7 +209,7 @@
end;
Meal.Date:= deDate.Date;
- //TODO: falta adicionar ao cardápio
+ //TODO: add to menu object
lbMeal.Clear;
UpdateMeal;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-06 01:52:03
|
Revision: 13
http://gotisso.svn.sourceforge.net/gotisso/?rev=13&view=rev
Author: jmvaz
Date: 2009-12-06 01:51:56 +0000 (Sun, 06 Dec 2009)
Log Message:
-----------
changed class routine names from Portuguese to English
Modified Paths:
--------------
trunk/lang/gotisso.po
trunk/u_main.lfm
trunk/u_main.lrt
trunk/u_main.pas
trunk/u_meal.pas
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2009-12-06 01:47:17 UTC (rev 12)
+++ trunk/lang/gotisso.po 2009-12-06 01:51:56 UTC (rev 13)
@@ -49,7 +49,8 @@
msgid "fmMain"
msgstr ""
-#: TFMMAIN.GBCARDAPIO.CAPTION
+#: TFMMAIN.GBMENU.CAPTION
+msgctxt "TFMMAIN.GBMENU.CAPTION"
msgid "Cardápio"
msgstr ""
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2009-12-06 01:47:17 UTC (rev 12)
+++ trunk/u_main.lfm 2009-12-06 01:51:56 UTC (rev 13)
@@ -10,7 +10,7 @@
Position = poScreenCenter
ShowHint = True
LCLVersion = '0.9.28.2'
- object gbCardapio: TGroupBox
+ object gbMenu: TGroupBox
Left = 24
Height = 361
Top = 24
Modified: trunk/u_main.lrt
===================================================================
--- trunk/u_main.lrt 2009-12-06 01:47:17 UTC (rev 12)
+++ trunk/u_main.lrt 2009-12-06 01:51:56 UTC (rev 13)
@@ -1,5 +1,5 @@
TFMMAIN.CAPTION=fmMain
-TFMMAIN.GBCARDAPIO.CAPTION=Cardápio
+TFMMAIN.GBMENU.CAPTION=Cardápio
TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION=Data
TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION=Pratos
TFMMAIN.BTNEW.CAPTION=Nova...
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-06 01:47:17 UTC (rev 12)
+++ trunk/u_main.pas 2009-12-06 01:51:56 UTC (rev 13)
@@ -40,7 +40,7 @@
btUp: TButton;
btPrint: TButton;
btRemove: TButton;
- gbCardapio: TGroupBox;
+ gbMenu: TGroupBox;
PrintDialog: TPrintDialog;
sgCardapio: TStringGrid;
procedure btPrintClick(Sender: TObject);
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-06 01:47:17 UTC (rev 12)
+++ trunk/u_meal.pas 2009-12-06 01:51:56 UTC (rev 13)
@@ -63,8 +63,8 @@
procedure lbMealClick(Sender: TObject);
private
{ private declarations }
- procedure UpdateRefeicao;
- function Adicionar: Boolean;
+ procedure UpdateMeal;
+ function Add: Boolean;
public
{ public declarations }
end;
@@ -88,7 +88,7 @@
begin
cbType.ItemIndex:= 0;
cbTypeChange(Sender); // já que alterar o ItemIndex não dispara esse evento...
- UpdateRefeicao;
+ UpdateMeal;
end;
procedure TfmMeal.cbTypeChange(Sender: TObject);
@@ -100,13 +100,13 @@
procedure TfmMeal.btAddClick(Sender: TObject);
begin
- if not Adicionar then
+ if not Add then
ShowMessage(sError);
end;
procedure TfmMeal.btAddAndCloseClick(Sender: TObject);
begin
- if not Adicionar then
+ if not Add then
ShowMessage(sError)
else
Close;
@@ -123,7 +123,7 @@
lbMeal.Items.Exchange(i, i+1);
lbMeal.Selected[i+1]:= True;
end;
- UpdateRefeicao;
+ UpdateMeal;
end;
procedure TfmMeal.btCloseClick(Sender: TObject);
@@ -135,13 +135,13 @@
procedure TfmMeal.btAddDishClick(Sender: TObject);
begin
lbMeal.Items.Add(cbDish.Items.Strings[cbDish.ItemIndex]);
- UpdateRefeicao;
+ UpdateMeal;
end;
procedure TfmMeal.btClearClick(Sender: TObject);
begin
lbMeal.Clear;
- UpdateRefeicao;
+ UpdateMeal;
end;
procedure TfmMeal.btRemoveClick(Sender: TObject);
@@ -151,7 +151,7 @@
for i:= (lbMeal.Count-1) downto 0 do
if lbMeal.Selected[i] then
lbMeal.Items.Delete(i);
- UpdateRefeicao;
+ UpdateMeal;
end;
procedure TfmMeal.btUpClick(Sender: TObject);
@@ -165,15 +165,15 @@
lbMeal.Items.Exchange(i, i-1);
lbMeal.Selected[i-1]:= True;
end;
- UpdateRefeicao;
+ UpdateMeal;
end;
procedure TfmMeal.lbMealClick(Sender: TObject);
begin
- UpdateRefeicao;
+ UpdateMeal;
end;
-procedure TfmMeal.UpdateRefeicao;
+procedure TfmMeal.UpdateMeal;
begin
btUp.Enabled:= ((lbMeal.SelCount > 0) and (not lbMeal.Selected[0]));
btDown.Enabled:= ((lbMeal.SelCount > 0) and (not lbMeal.Selected[lbMeal.Count-1]));
@@ -183,7 +183,7 @@
btAddAndClose.Enabled:= btAdd.Enabled;
end;
-function TfmMeal.Adicionar: Boolean;
+function TfmMeal.Add: Boolean;
var
Meal: TMeal;
i: Integer;
@@ -200,7 +200,7 @@
//TODO: falta adicionar ao cardápio
lbMeal.Clear;
- UpdateRefeicao;
+ UpdateMeal;
except
Result:= False;
end;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-06 01:47:24
|
Revision: 12
http://gotisso.svn.sourceforge.net/gotisso/?rev=12&view=rev
Author: jmvaz
Date: 2009-12-06 01:47:17 +0000 (Sun, 06 Dec 2009)
Log Message:
-----------
corrected dishes down routine and added dishes up routine on the Meal listbox
Modified Paths:
--------------
trunk/u_meal.pas
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-04 18:35:45 UTC (rev 11)
+++ trunk/u_meal.pas 2009-12-06 01:47:17 UTC (rev 12)
@@ -118,7 +118,12 @@
begin
for i:= (lbMeal.Count-2) downto 0 do
if lbMeal.Selected[i] then
- lbMeal.Items.Exchange(i, i+1); //TODO: não está funcionando a contento: é necessário trocar os selecionados
+ begin
+ lbMeal.Selected[i]:= lbMeal.Selected[i+1];
+ lbMeal.Items.Exchange(i, i+1);
+ lbMeal.Selected[i+1]:= True;
+ end;
+ UpdateRefeicao;
end;
procedure TfmMeal.btCloseClick(Sender: TObject);
@@ -153,7 +158,14 @@
var
i: Integer;
begin
-
+ for i:= 1 to (lbMeal.Count-1) do
+ if lbMeal.Selected[i] then
+ begin
+ lbMeal.Selected[i]:= lbMeal.Selected[i-1];
+ lbMeal.Items.Exchange(i, i-1);
+ lbMeal.Selected[i-1]:= True;
+ end;
+ UpdateRefeicao;
end;
procedure TfmMeal.lbMealClick(Sender: TObject);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-04 18:35:52
|
Revision: 11
http://gotisso.svn.sourceforge.net/gotisso/?rev=11&view=rev
Author: jmvaz
Date: 2009-12-04 18:35:45 +0000 (Fri, 04 Dec 2009)
Log Message:
-----------
changed classes names from portuguese to english
Modified Paths:
--------------
trunk/gotisso.lpi
trunk/u_classes.pas
trunk/u_main.pas
trunk/u_meal.pas
Modified: trunk/gotisso.lpi
===================================================================
--- trunk/gotisso.lpi 2009-12-04 17:53:02 UTC (rev 10)
+++ trunk/gotisso.lpi 2009-12-04 18:35:45 UTC (rev 11)
@@ -4,6 +4,11 @@
<PathDelim Value="\"/>
<Version Value="7"/>
<General>
+ <Flags>
+ <SaveClosedFiles Value="False"/>
+ <SaveOnlyProjectUnits Value="True"/>
+ <AlwaysBuild Value="False"/>
+ </Flags>
<SessionStorage Value="InProjectDir"/>
<MainUnit Value="0"/>
<TargetFileExt Value=".exe"/>
Modified: trunk/u_classes.pas
===================================================================
--- trunk/u_classes.pas 2009-12-04 17:53:02 UTC (rev 10)
+++ trunk/u_classes.pas 2009-12-04 18:35:45 UTC (rev 11)
@@ -30,146 +30,147 @@
type
- { TPrato }
+ { TDish }
- TPrato = class(TPersistent)
+ TDish = class(TPersistent)
private
- fIngredientes: TStringList;
- fNome: String;
- fTipo: String;
- procedure SetIngredientes(const AValue: TStringList);
- procedure SetNome(const AValue: String);
- procedure SetTipo(const AValue: String);
+ fDishType: String;
+ fIngredients: TStringList;
+ fName: String;
+ procedure SetDishType(const AValue: String);
+ procedure SetIngredients(const AValue: TStringList);
+ procedure SetName(const AValue: String);
public
constructor Create; overload;
- constructor Create(ANome,ATipo: String); overload;
+ constructor Create(AName,ADishType: String); overload;
destructor Destroy; override;
procedure Assign(Source: TPersistent); override;
- property Nome: String read fNome write SetNome;
- property Tipo: String read fTipo write SetTipo;
- property Ingredientes: TStringList read fIngredientes write SetIngredientes;
+ property Name: String read fName write SetName;
+ property DishType: String read fDishType write SetDishType;
+ property Ingredients: TStringList read fIngredients write SetIngredients;
end;
- { TPratos }
+ { TDishes }
- TPratos = class
+ TDishes = class
private
- fLista: TStringList;
+ fList: TStringList;
protected
- function GetTodosTipos: TStringList; virtual;
- function GetTodosIngredientes: TStringList; virtual;
- function GetTodosPratos: TStringList; virtual;
- function GetTotal: Integer; virtual;
- function GetPrato(Index: Integer): TPrato; virtual;
+ function GetAllDishTypes: TStringList; virtual;
+ function GetAllIngredients: TStringList; virtual;
+ function GetAllDishes: TStringList; virtual;
+ function GetCount: Integer; virtual;
+ function GetDish(Index: Integer): TDish; virtual;
public
constructor Create;
destructor Destroy; override;
- function PratosPorTipo(ATipo: String): TPratos; virtual;
- function PratosPorIngrediente(AIngrediente: String): TPratos; virtual;
- function PratoPorNome(ANome: String): TPrato; virtual;
- procedure AdicionaPrato(APrato: TPrato);
- function RemovePrato(ANome: String): Boolean; overload;
- function RemovePrato(APrato: TPrato): Boolean; overload;
- procedure Limpar;
- property TodosTipos: TStringList read GetTodosTipos;
- property TodosIngredientes: TStringList read GetTodosIngredientes;
- property TodosPratos: TStringList read GetTodosPratos;
- property Total: Integer read GetTotal;
- property Prato[Index: Integer]: TPrato read GetPrato;
+ function DishesByDishType(ADishType: String): TDishes; virtual;
+ function DishesByIngredient(AIngredient: String): TDishes; virtual;
+ function DishByName(AName: String): TDish; virtual;
+ procedure AddDish(ADish: TDish);
+ function RemoveDish(AName: String): Boolean; overload;
+ function RemoveDish(ADish: TDish): Boolean; overload;
+ procedure Clear;
+ property AllDishTypes: TStringList read GetAllDishTypes;
+ property AllIngredients: TStringList read GetAllIngredients;
+ property AllDishes: TStringList read GetAllDishes;
+ property Count: Integer read GetCount;
+ property Dish[Index: Integer]: TDish read GetDish;
end;
- { TPratosDB }
+ { TDishesDB }
- TPratosDB = class(TPratos)
+ TDishesDB = class(TDishes)
private
public
function LoadFromFile(AFileName: TFileName): Boolean;
end;
- { TRefeicao }
+ { TMeal }
- TRefeicao = class
+ TMeal = class
private
- fPratos: TPratos;
- fData: TDateTime;
+ fDishes: TDishes;
+ fDate: TDateTime;
protected
- procedure SetData(const AValue: TdateTime);
- procedure SetPratos(const AValue: TPratos);
+ procedure SetDate(const AValue: TDateTime);
+ procedure SetDishes(const AValue: TDishes);
public
constructor Create; overload;
- constructor Create(AData: TDateTime; APratos: TPratos); overload;
+ constructor Create(ADate: TDateTime; ADishes: TDishes); overload;
destructor Destroy; override;
- procedure AdicionaPrato(APrato: TPrato);
- procedure Limpar;
- function RemovePrato(APrato: String): Boolean; overload;
- function RemovePrato(APrato: TPrato): Boolean; overload;
- property Data: TdateTime read fData write SetData;
- property Pratos: TPratos read fPratos write SetPratos;
+ procedure AddDish(ADish: TDish);
+ procedure Clear;
+ function RemoveDish(ADish: String): Boolean; overload;
+ function RemoveDish(ADish: TDish): Boolean; overload;
+ property Date: TDateTime read fDate write SetDate;
+ property Dishes: TDishes read fDishes write SetDishes;
end;
var
- Pratos: TPratosDB;
+ Dishes: TDishesDB;
implementation
-{ TPrato }
+{ TDish }
-procedure TPrato.SetIngredientes(const AValue: TStringList);
+
+procedure TDish.SetDishType(const AValue: String);
begin
- if FIngredientes=AValue then exit;
- FIngredientes.Assign(AValue);
+ if fDishType = AValue then exit;
+ fDishType:= AValue;
end;
-procedure TPrato.SetNome(const AValue: String);
+procedure TDish.SetIngredients(const AValue: TStringList);
begin
- if FNome=AValue then exit;
- FNome:=AValue;
+ if fIngredients = AValue then exit;
+ fIngredients:= AValue;
end;
-procedure TPrato.SetTipo(const AValue: String);
+procedure TDish.SetName(const AValue: String);
begin
- if FTipo=AValue then exit;
- FTipo:=AValue;
+ if fName = AValue then exit;
+ fName:= AValue;
end;
-constructor TPrato.Create;
+constructor TDish.Create;
begin
- FIngredientes:= TStringList.Create;
+ fIngredients:= TStringList.Create;
end;
-constructor TPrato.Create(ANome, ATipo: String);
+constructor TDish.Create(AName, ADishType: String);
begin
Self.Create;
- Self.Tipo:= ATipo;
- Self.Nome:= ANome;
+ Self.DishType:= ADishType;
+ Self.Name:= AName;
end;
-destructor TPrato.Destroy;
+destructor TDish.Destroy;
begin
- FIngredientes.Clear;
- FIngredientes.Free;
+ FIngredients.Clear;
+ FIngredients.Free;
inherited Destroy;
end;
-procedure TPrato.Assign(Source: TPersistent);
+procedure TDish.Assign(Source: TPersistent);
begin
- if (Source <> Nil) and (Source is TPrato) then
+ if (Source <> Nil) and (Source is TDish) then
begin
- Nome:= TPrato(Source).Nome;
- Tipo:= TPrato(Source).Tipo;
- Ingredientes.Assign(TPrato(Source).Ingredientes);
+ Name:= TDish(Source).Name;
+ DishType:= TDish(Source).DishType;
+ Ingredients.Assign(TDish(Source).Ingredients);
end
else
inherited Assign(Source);
end;
-{ TPratos }
+{ TDishes }
-function TPratos.GetTodosTipos: TStringList;
+function TDishes.GetAllDishTypes: TStringList;
var
i: Integer;
begin
@@ -177,14 +178,14 @@
try
Result.Sorted:= True;
Result.Duplicates:= dupIgnore;
- for i:= 0 to (fLista.Count-1) do
- Result.Add(TPrato(fLista.Objects[i]).Tipo);
+ for i:= 0 to (fList.Count-1) do
+ Result.Add(TDish(fList.Objects[i]).DishType);
except
Result:= nil;
end;
end;
-function TPratos.GetTodosIngredientes: TStringList;
+function TDishes.GetAllIngredients: TStringList;
var
i,j: Integer;
begin
@@ -192,15 +193,15 @@
try
Result.Sorted:= True;
Result.Duplicates:= dupIgnore;
- for i:= 0 to (fLista.Count-1) do
- for j:= 0 to (TPrato(fLista.Objects[i]).Ingredientes.Count-1) do
- Result.Add(TPrato(fLista.Objects[i]).Ingredientes.Strings[j]);
+ for i:= 0 to (fList.Count-1) do
+ for j:= 0 to (TDish(fList.Objects[i]).Ingredients.Count-1) do
+ Result.Add(TDish(fList.Objects[i]).Ingredients.Strings[j]);
except
Result:= nil;
end;
end;
-function TPratos.GetTodosPratos: TStringList;
+function TDishes.GetAllDishes: TStringList;
var
i: Integer;
begin
@@ -208,166 +209,166 @@
try
Result.Sorted:= True;
Result.Duplicates:= dupIgnore;
- for i:= 0 to (fLista.Count-1) do
- Result.Add(TPrato(fLista.Objects[i]).Nome);
+ for i:= 0 to (fList.Count-1) do
+ Result.Add(TDish(fList.Objects[i]).Name);
except
Result:= nil;
end;
end;
-function TPratos.GetTotal: Integer;
+function TDishes.GetCount: Integer;
begin
- Result:= fLista.Count;
+ Result:= fList.Count;
end;
-function TPratos.GetPrato(Index: Integer): TPrato;
+function TDishes.GetDish(Index: Integer): TDish;
begin
- if ((Index >= 0) and (Index < fLista.Count)) then
- Result:= (fLista.Objects[Index] as TPrato);
+ if ((Index >= 0) and (Index < fList.Count)) then
+ Result:= (fList.Objects[Index] as TDish);
end;
-constructor TPratos.Create;
+constructor TDishes.Create;
begin
- fLista:= TStringList.Create;
+ fList:= TStringList.Create;
end;
-destructor TPratos.Destroy;
+destructor TDishes.Destroy;
begin
- Limpar;
- fLista.Free;
+ Clear;
+ fList.Free;
inherited Destroy;
end;
-function TPratos.PratosPorTipo(ATipo: String): TPratos;
+function TDishes.DishesByDishType(ADishType: String): TDishes;
var
i: Integer;
begin
- Result:= TPratos.Create;
+ Result:= TDishes.Create;
try
- for i:= 0 to (fLista.Count-1) do
- if TPrato(fLista.Objects[i]).Tipo = ATipo then
- Result.AdicionaPrato(TPrato(fLista.Objects[i]));
+ for i:= 0 to (fList.Count-1) do
+ if TDish(fList.Objects[i]).DishType = ADishType then
+ Result.AddDish(TDish(fList.Objects[i]));
except
Result:= nil;
end;
end;
-function TPratos.PratosPorIngrediente(AIngrediente: String): TPratos;
+function TDishes.DishesByIngredient(AIngredient: String): TDishes;
var
i: Integer;
begin
- Result:= TPratos.Create;
+ Result:= TDishes.Create;
try
- for i:= 0 to (fLista.Count-1) do
- if (TPrato(fLista.Objects[i]).Ingredientes.IndexOf(AIngrediente) > -1) then
- Result.AdicionaPrato(TPrato(fLista.Objects[i]));
+ for i:= 0 to (fList.Count-1) do
+ if (TDish(fList.Objects[i]).Ingredients.IndexOf(AIngredient) > -1) then
+ Result.AddDish(TDish(fList.Objects[i]));
except
Result:= nil;
end;
end;
-function TPratos.PratoPorNome(ANome: String): TPrato;
+function TDishes.DishByName(AName: String): TDish;
var
i: Integer;
begin
- Result:= TPrato.Create;
- for i:= 0 to (fLista.Count-1) do
- if TPrato(fLista.Objects[i]).Nome = ANome then
- Result.Assign(TPrato(fLista.Objects[i]));
+ Result:= TDish.Create;
+ for i:= 0 to (fList.Count-1) do
+ if TDish(fList.Objects[i]).Name = AName then
+ Result.Assign(TDish(fList.Objects[i]));
end;
-procedure TPratos.AdicionaPrato(APrato: TPrato);
+procedure TDishes.AddDish(ADish: TDish);
begin
- fLista.AddObject(APrato.Nome,APrato);
+ fList.AddObject(ADish.Name,ADish);
end;
-function TPratos.RemovePrato(ANome: String): Boolean;
+function TDishes.RemoveDish(AName: String): Boolean;
var
i: Integer;
begin
- for i:= 0 to (fLista.Count-1) do
- if TPrato(fLista.Objects[i]).Nome = ANome then
+ for i:= 0 to (fList.Count-1) do
+ if TDish(fList.Objects[i]).Name = AName then
begin
- TPrato(fLista.Objects[i]).Free;
- fLista.Delete(i);
+ TDish(fList.Objects[i]).Free;
+ fList.Delete(i);
Result:= True;
end;
end;
-function TPratos.RemovePrato(APrato: TPrato): Boolean;
+function TDishes.RemoveDish(ADish: TDish): Boolean;
begin
- Result:= RemovePrato(APrato.Nome);
+ Result:= RemoveDish(ADish.Name);
end;
-procedure TPratos.Limpar;
+procedure TDishes.Clear;
begin
- fLista.Clear;
+ fList.Clear;
end;
-{ TPratosDB }
+{ TDishesDB }
-function TPratosDB.LoadFromFile(AFileName: TFileName): Boolean;
+function TDishesDB.LoadFromFile(AFileName: TFileName): Boolean;
begin
end;
-{ TRefeicao }
+{ TMeal }
-procedure TRefeicao.SetData(const AValue: TDateTime);
+procedure TMeal.SetDate(const AValue: TDateTime);
begin
- if fData = AValue then exit;
- fData:=AValue;
+ if fDate = AValue then exit;
+ fDate:=AValue;
end;
-procedure TRefeicao.SetPratos(const AValue: TPratos);
+procedure TMeal.SetDishes(const AValue: TDishes);
var
i: Integer;
begin
- fPratos.Limpar;
- for i:= 0 to AValue.Total-1 do
- fPratos.AdicionaPrato(AValue.Prato[i]);
+ fDishes.Clear;
+ for i:= 0 to AValue.Count-1 do
+ fDishes.AddDish(AValue.Dish[i]);
end;
-constructor TRefeicao.Create;
+constructor TMeal.Create;
begin
- fPratos:= TPratos.Create;
- fData:= Date;
+ fDishes:= TDishes.Create;
+ fDate:= Date;
end;
-constructor TRefeicao.Create(AData: TDateTime; APratos: TPratos);
+constructor TMeal.Create(ADate: TDateTime; ADishes: TDishes);
begin
Self.Create;
- Self.Data:= AData;
- Self.Pratos:= APratos;
+ Self.Date:= ADate;
+ Self.Dishes:= ADishes;
end;
-destructor TRefeicao.Destroy;
+destructor TMeal.Destroy;
begin
inherited Destroy;
end;
-procedure TRefeicao.AdicionaPrato(APrato: TPrato);
+procedure TMeal.AddDish(ADish: TDish);
begin
- fPratos.AdicionaPrato(APrato);
+ fDishes.AddDish(ADish);
end;
-procedure TRefeicao.Limpar;
+procedure TMeal.Clear;
begin
- Pratos.Limpar;
- Data:= Date;
+ Dishes.Clear;
+ Date:= Now;
end;
-function TRefeicao.RemovePrato(APrato: String): Boolean;
+function TMeal.RemoveDish(ADish: String): Boolean;
begin
- Result:= fPratos.RemovePrato(APrato);
+ Result:= fDishes.RemoveDish(ADish);
end;
-function TRefeicao.RemovePrato(APrato: TPrato): Boolean;
+function TMeal.RemoveDish(ADish: TDish): Boolean;
begin
- Result:= fPratos.RemovePrato(APrato);
+ Result:= fDishes.RemoveDish(ADish);
end;
end.
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-04 17:53:02 UTC (rev 10)
+++ trunk/u_main.pas 2009-12-04 18:35:45 UTC (rev 11)
@@ -66,19 +66,19 @@
procedure TfmMain.FormCreate(Sender: TObject);
begin
Caption:= sTitle;
- Pratos:= TPratosDB.Create;
+ Dishes:= TDishesDB.Create;
// testes temporários
- Pratos.AdicionaPrato(TPrato.Create('Bife a milanesa','carne'));
- Pratos.AdicionaPrato(TPrato.Create('Frango a milanesa','carne'));
- Pratos.AdicionaPrato(TPrato.Create('Frango a milanesa','carne'));
- Pratos.AdicionaPrato(TPrato.Create('Filé de peixe','carne'));
- Pratos.AdicionaPrato(TPrato.Create('Arroz','carboidrato'));
- Pratos.AdicionaPrato(TPrato.Create('Purê de batatas','carboidrato'));
- Pratos.AdicionaPrato(TPrato.Create('Macarrão','carboidrato'));
- Pratos.AdicionaPrato(TPrato.Create('Feijão','leguminosa'));
- Pratos.AdicionaPrato(TPrato.Create('Grão de bico','leguminosa'));
+ Dishes.AddDish(TDish.Create('Bife a milanesa','carne'));
+ Dishes.AddDish(TDish.Create('Frango a milanesa','carne'));
+ Dishes.AddDish(TDish.Create('Frango a milanesa','carne'));
+ Dishes.AddDish(TDish.Create('Filé de peixe','carne'));
+ Dishes.AddDish(TDish.Create('Arroz','carboidrato'));
+ Dishes.AddDish(TDish.Create('Purê de batatas','carboidrato'));
+ Dishes.AddDish(TDish.Create('Macarrão','carboidrato'));
+ Dishes.AddDish(TDish.Create('Feijão','leguminosa'));
+ Dishes.AddDish(TDish.Create('Grão de bico','leguminosa'));
// fim dos testes temporários
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-04 17:53:02 UTC (rev 10)
+++ trunk/u_meal.pas 2009-12-04 18:35:45 UTC (rev 11)
@@ -81,7 +81,7 @@
procedure TfmMeal.FormCreate(Sender: TObject);
begin
- cbType.Items.Assign(Pratos.TodosTipos);
+ cbType.Items.Assign(Dishes.AllDishTypes);
end;
procedure TfmMeal.FormShow(Sender: TObject);
@@ -93,7 +93,7 @@
procedure TfmMeal.cbTypeChange(Sender: TObject);
begin
- cbDish.Items.Assign(Pratos.PratosPorTipo(cbType.Items[cbType.ItemIndex]).TodosPratos);
+ cbDish.Items.Assign(Dishes.DishesByDishType(cbType.Items[cbType.ItemIndex]).AllDishes);
cbDish.ItemIndex:= 0;
end;
@@ -173,17 +173,17 @@
function TfmMeal.Adicionar: Boolean;
var
- Refeicao: TRefeicao;
+ Meal: TMeal;
i: Integer;
begin
Result:= False;
- Refeicao:= TRefeicao.Create;
+ Meal:= TMeal.Create;
try
for i:= 0 to (lbMeal.Count-1) do
begin
- Refeicao.AdicionaPrato(Pratos.PratoPorNome(lbMeal.Items.Strings[i]));
+ Meal.AddDish(Dishes.DishByName(lbMeal.Items.Strings[i]));
end;
- Refeicao.Data:= deDate.Date;
+ Meal.Date:= deDate.Date;
//TODO: falta adicionar ao cardápio
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-04 17:53:12
|
Revision: 10
http://gotisso.svn.sourceforge.net/gotisso/?rev=10&view=rev
Author: jmvaz
Date: 2009-12-04 17:53:02 +0000 (Fri, 04 Dec 2009)
Log Message:
-----------
program output dir changed (creating output dir)
Added Paths:
-----------
trunk/output/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-04 17:50:03
|
Revision: 9
http://gotisso.svn.sourceforge.net/gotisso/?rev=9&view=rev
Author: jmvaz
Date: 2009-12-04 17:49:56 +0000 (Fri, 04 Dec 2009)
Log Message:
-----------
changed component names from portuguese to english
Modified Paths:
--------------
trunk/gotisso.lpr
trunk/lang/gotisso.po
trunk/u_ingredients.lfm
trunk/u_ingredients.lrt
trunk/u_ingredients.pas
trunk/u_main.lfm
trunk/u_main.lrt
trunk/u_main.pas
trunk/u_meal.lfm
trunk/u_meal.lrt
trunk/u_meal.pas
Modified: trunk/gotisso.lpr
===================================================================
--- trunk/gotisso.lpr 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/gotisso.lpr 2009-12-04 17:49:56 UTC (rev 9)
@@ -38,8 +38,8 @@
Application.Title:= sTitle;
Application.Initialize;
Application.CreateForm(TfmMain, fmMain);
+ Application.CreateForm(TfmMeal, fmMeal);
Application.CreateForm(TfmIngredients, fmIngredients);
- Application.CreateForm(TfmMeal, fmMeal);
Application.Run;
end.
Modified: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/lang/gotisso.po 2009-12-04 17:49:56 UTC (rev 9)
@@ -1,69 +1,55 @@
msgid ""
msgstr "Content-Type: text/plain; charset=UTF-8"
-#: TFMINGREDIENTES.BTFECHAR.CAPTION
-msgctxt "TFMINGREDIENTES.BTFECHAR.CAPTION"
+#: TFMINGREDIENTS.BTCLOSE.CAPTION
+msgctxt "TFMINGREDIENTS.BTCLOSE.CAPTION"
msgid "Fechar"
msgstr ""
-#: TFMINGREDIENTES.BTIMPRIMIR.CAPTION
-msgctxt "TFMINGREDIENTES.BTIMPRIMIR.CAPTION"
+#: TFMINGREDIENTS.BTPRINT.CAPTION
+msgctxt "TFMINGREDIENTS.BTPRINT.CAPTION"
msgid "Imprimir..."
msgstr ""
-#: TFMINGREDIENTES.CAPTION
-msgctxt "TFMINGREDIENTES.CAPTION"
+#: TFMINGREDIENTS.CAPTION
msgid "Ingredientes"
msgstr ""
-#: TFMINGREDIENTS.BTFECHAR.CAPTION
-msgctxt "TFMINGREDIENTS.BTFECHAR.CAPTION"
-msgid "Fechar"
+#: TFMMAIN.BTCLEAR.CAPTION
+msgctxt "TFMMAIN.BTCLEAR.CAPTION"
+msgid "Limpar"
msgstr ""
-#: TFMINGREDIENTS.BTIMPRIMIR.CAPTION
-msgctxt "TFMINGREDIENTS.BTIMPRIMIR.CAPTION"
-msgid "Imprimir..."
+#: TFMMAIN.BTDOWN.CAPTION
+msgid "Down"
msgstr ""
-#: TFMINGREDIENTS.CAPTION
-msgctxt "TFMINGREDIENTS.CAPTION"
-msgid "Ingredientes"
+#: TFMMAIN.BTINGREDIENTS.CAPTION
+msgid "Lista de Ingredientes..."
msgstr ""
-#: TFMMAIN.BTCARLIMPAR.CAPTION
-msgctxt "TFMMAIN.BTCARLIMPAR.CAPTION"
-msgid "Limpar"
+#: TFMMAIN.BTNEW.CAPTION
+msgid "Nova..."
msgstr ""
-#: TFMMAIN.BTCARREMOVER.CAPTION
-msgctxt "TFMMAIN.BTCARREMOVER.CAPTION"
-msgid "Remover"
-msgstr ""
-
-#: TFMMAIN.BTIMPRIMIR.CAPTION
-msgctxt "TFMMAIN.BTIMPRIMIR.CAPTION"
+#: TFMMAIN.BTPRINT.CAPTION
+msgctxt "TFMMAIN.BTPRINT.CAPTION"
msgid "Imprimir..."
msgstr ""
-#: TFMMAIN.BTINGREDIENTES.CAPTION
-msgid "Lista de Ingredientes..."
+#: TFMMAIN.BTREMOVE.CAPTION
+msgid "Remove"
msgstr ""
-#: TFMMAIN.BTNOVA.CAPTION
-msgid "Nova..."
+#: TFMMAIN.BTUP.CAPTION
+msgid "Up"
msgstr ""
-#: TFMMAIN.BUTTON8.CAPTION
-msgid "Button1"
-msgstr ""
-
#: TFMMAIN.CAPTION
msgid "fmMain"
msgstr ""
#: TFMMAIN.GBCARDAPIO.CAPTION
-msgctxt "TFMMAIN.GBCARDAPIO.CAPTION"
msgid "Cardápio"
msgstr ""
@@ -71,43 +57,39 @@
msgid "Pratos"
msgstr ""
-#: TFMMEAL.BTADICIONAR.CAPTION
-msgctxt "TFMMEAL.BTADICIONAR.CAPTION"
+#: TFMMEAL.BTADD.CAPTION
+msgctxt "TFMMEAL.BTADD.CAPTION"
msgid "Adicionar"
msgstr ""
-#: TFMMEAL.BTADICIONAREFECHAR.CAPTION
-msgctxt "TFMMEAL.BTADICIONAREFECHAR.CAPTION"
+#: TFMMEAL.BTADDANDCLOSE.CAPTION
msgid "Adicionar e Fechar"
msgstr ""
-#: TFMMEAL.BTDOWN.CAPTION
-msgctxt "TFMMEAL.BTDOWN.CAPTION"
-msgid "Abaixo"
+#: TFMMEAL.BTADDDISH.CAPTION
+msgctxt "TFMMEAL.BTADDDISH.CAPTION"
+msgid "Adicionar"
msgstr ""
-#: TFMMEAL.BTFECHAR.CAPTION
-msgctxt "TFMMEAL.BTFECHAR.CAPTION"
-msgid "Fechar"
+#: TFMMEAL.BTCLEAR.CAPTION
+msgctxt "TFMMEAL.BTCLEAR.CAPTION"
+msgid "Limpar"
msgstr ""
-#: TFMMEAL.BTLIMPAR.CAPTION
-msgctxt "TFMMEAL.BTLIMPAR.CAPTION"
-msgid "Limpar"
+#: TFMMEAL.BTCLOSE.CAPTION
+msgctxt "TFMMEAL.BTCLOSE.CAPTION"
+msgid "Fechar"
msgstr ""
-#: TFMMEAL.BTPRATO.CAPTION
-msgctxt "TFMMEAL.BTPRATO.CAPTION"
-msgid "Adicionar"
+#: TFMMEAL.BTDOWN.CAPTION
+msgid "Abaixo"
msgstr ""
-#: TFMMEAL.BTREMOVER.CAPTION
-msgctxt "TFMMEAL.BTREMOVER.CAPTION"
+#: TFMMEAL.BTREMOVE.CAPTION
msgid "Remover"
msgstr ""
#: TFMMEAL.BTUP.CAPTION
-msgctxt "TFMMEAL.BTUP.CAPTION"
msgid "Acima"
msgstr ""
@@ -115,117 +97,31 @@
msgid "fmMeal"
msgstr ""
-#: TFMMEAL.DEDATA.CANCELCAPTION
-msgctxt "TFMMEAL.DEDATA.CANCELCAPTION"
+#: TFMMEAL.DEDATE.CANCELCAPTION
msgid "Cancelar"
msgstr ""
-#: TFMMEAL.DEDATA.DIALOGTITLE
-msgctxt "TFMMEAL.DEDATA.DIALOGTITLE"
+#: TFMMEAL.DEDATE.DIALOGTITLE
msgid "Escolha a data"
msgstr ""
-#: TFMMEAL.DEDATA.OKCAPTION
-msgctxt "TFMMEAL.DEDATA.OKCAPTION"
+#: TFMMEAL.DEDATE.OKCAPTION
msgid "OK"
msgstr ""
-#: TFMMEAL.GBREFEICAO.CAPTION
-msgctxt "TFMMEAL.GBREFEICAO.CAPTION"
+#: TFMMEAL.GBMEAL.CAPTION
msgid "Refeição"
msgstr ""
-#: TFMMEAL.LBLREFEICAO.CAPTION
-msgctxt "TFMMEAL.LBLREFEICAO.CAPTION"
-msgid "Refeição:"
-msgstr ""
-
-#: TFMMEAL.LBPRATO.CAPTION
-msgctxt "TFMMEAL.LBPRATO.CAPTION"
+#: TFMMEAL.LBDISH.CAPTION
msgid "Prato:"
msgstr ""
-#: TFMMEAL.LBTIPO.CAPTION
-msgctxt "TFMMEAL.LBTIPO.CAPTION"
-msgid "Tipo:"
-msgstr ""
-
-#: TFMREFEICAO.BTADICIONAR.CAPTION
-msgctxt "TFMREFEICAO.BTADICIONAR.CAPTION"
-msgid "Adicionar"
-msgstr ""
-
-#: TFMREFEICAO.BTADICIONAREFECHAR.CAPTION
-msgctxt "TFMREFEICAO.BTADICIONAREFECHAR.CAPTION"
-msgid "Adicionar e Fechar"
-msgstr ""
-
-#: TFMREFEICAO.BTDOWN.CAPTION
-msgctxt "TFMREFEICAO.BTDOWN.CAPTION"
-msgid "Abaixo"
-msgstr ""
-
-#: TFMREFEICAO.BTFECHAR.CAPTION
-msgctxt "TFMREFEICAO.BTFECHAR.CAPTION"
-msgid "Fechar"
-msgstr ""
-
-#: TFMREFEICAO.BTLIMPAR.CAPTION
-msgctxt "TFMREFEICAO.BTLIMPAR.CAPTION"
-msgid "Limpar"
-msgstr ""
-
-#: TFMREFEICAO.BTPRATO.CAPTION
-msgctxt "TFMREFEICAO.BTPRATO.CAPTION"
-msgid "Adicionar"
-msgstr ""
-
-#: TFMREFEICAO.BTREMOVER.CAPTION
-msgctxt "TFMREFEICAO.BTREMOVER.CAPTION"
-msgid "Remover"
-msgstr ""
-
-#: TFMREFEICAO.BTUP.CAPTION
-msgctxt "TFMREFEICAO.BTUP.CAPTION"
-msgid "Acima"
-msgstr ""
-
-#: TFMREFEICAO.CAPTION
-msgid "fmRefeicao"
-msgstr ""
-
-#: TFMREFEICAO.DEDATA.CANCELCAPTION
-msgctxt "TFMREFEICAO.DEDATA.CANCELCAPTION"
-msgid "Cancelar"
-msgstr ""
-
-#: TFMREFEICAO.DEDATA.DIALOGTITLE
-msgctxt "TFMREFEICAO.DEDATA.DIALOGTITLE"
-msgid "Escolha a data"
-msgstr ""
-
-#: TFMREFEICAO.DEDATA.OKCAPTION
-msgctxt "TFMREFEICAO.DEDATA.OKCAPTION"
-msgid "OK"
-msgstr ""
-
-#: TFMREFEICAO.GBREFEICAO.CAPTION
-msgctxt "TFMREFEICAO.GBREFEICAO.CAPTION"
-msgid "Refeição"
-msgstr ""
-
-#: TFMREFEICAO.LBLREFEICAO.CAPTION
-msgctxt "TFMREFEICAO.LBLREFEICAO.CAPTION"
+#: TFMMEAL.LBLMEAL.CAPTION
msgid "Refeição:"
msgstr ""
-#: TFMREFEICAO.LBPRATO.CAPTION
-msgctxt "TFMREFEICAO.LBPRATO.CAPTION"
-msgid "Prato:"
-msgstr ""
-
-#: TFMREFEICAO.LBTIPO.CAPTION
-msgctxt "TFMREFEICAO.LBTIPO.CAPTION"
+#: TFMMEAL.LBTYPE.CAPTION
msgid "Tipo:"
msgstr ""
@@ -234,7 +130,6 @@
msgstr ""
#: u_consts.stitle
-msgctxt "u_consts.stitle"
msgid "Gotisso Meal Planner"
msgstr ""
Modified: trunk/u_ingredients.lfm
===================================================================
--- trunk/u_ingredients.lfm 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_ingredients.lfm 2009-12-04 17:49:56 UTC (rev 9)
@@ -7,7 +7,7 @@
ClientHeight = 300
ClientWidth = 400
LCLVersion = '0.9.28.2'
- object ListBox1: TListBox
+ object lbIngredients: TListBox
Left = 24
Height = 218
Top = 16
@@ -15,24 +15,24 @@
ItemHeight = 0
TabOrder = 0
end
- object btImprimir: TButton
+ object btPrint: TButton
Left = 24
Height = 25
Top = 248
Width = 75
Caption = 'Imprimir...'
Default = True
- OnClick = btImprimirClick
+ OnClick = btPrintClick
TabOrder = 1
end
- object btFechar: TButton
+ object btClose: TButton
Left = 301
Height = 25
Top = 252
Width = 75
Cancel = True
Caption = 'Fechar'
- OnClick = btFecharClick
+ OnClick = btCloseClick
TabOrder = 2
end
object PrintDialog: TPrintDialog
Modified: trunk/u_ingredients.lrt
===================================================================
--- trunk/u_ingredients.lrt 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_ingredients.lrt 2009-12-04 17:49:56 UTC (rev 9)
@@ -1,3 +1,3 @@
TFMINGREDIENTS.CAPTION=Ingredientes
-TFMINGREDIENTS.BTIMPRIMIR.CAPTION=Imprimir...
-TFMINGREDIENTS.BTFECHAR.CAPTION=Fechar
+TFMINGREDIENTS.BTPRINT.CAPTION=Imprimir...
+TFMINGREDIENTS.BTCLOSE.CAPTION=Fechar
Modified: trunk/u_ingredients.pas
===================================================================
--- trunk/u_ingredients.pas 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_ingredients.pas 2009-12-04 17:49:56 UTC (rev 9)
@@ -33,12 +33,12 @@
{ TfmIngredients }
TfmIngredients = class(TForm)
- btImprimir: TButton;
- btFechar: TButton;
- ListBox1: TListBox;
+ btPrint: TButton;
+ btClose: TButton;
+ lbIngredients: TListBox;
PrintDialog: TPrintDialog;
- procedure btFecharClick(Sender: TObject);
- procedure btImprimirClick(Sender: TObject);
+ procedure btCloseClick(Sender: TObject);
+ procedure btPrintClick(Sender: TObject);
private
{ private declarations }
public
@@ -52,7 +52,7 @@
{ TfmIngredients }
-procedure TfmIngredients.btImprimirClick(Sender: TObject);
+procedure TfmIngredients.btPrintClick(Sender: TObject);
begin
if PrintDialog.Execute then
begin
@@ -60,7 +60,7 @@
end;
end;
-procedure TfmIngredients.btFecharClick(Sender: TObject);
+procedure TfmIngredients.btCloseClick(Sender: TObject);
begin
Close;
end;
Modified: trunk/u_main.lfm
===================================================================
--- trunk/u_main.lfm 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_main.lfm 2009-12-04 17:49:56 UTC (rev 9)
@@ -41,24 +41,24 @@
310
)
end
- object btNova: TButton
+ object btNew: TButton
Left = 413
Height = 25
Top = 17
Width = 75
Caption = 'Nova...'
- OnClick = btNovaClick
+ OnClick = btNewClick
TabOrder = 1
end
- object btCarRemover: TButton
+ object btDown: TButton
Left = 413
Height = 25
- Top = 136
+ Top = 96
Width = 75
- Caption = 'Remover'
+ Caption = 'Down'
TabOrder = 2
end
- object btCarLimpar: TButton
+ object btClear: TButton
Left = 413
Height = 25
Top = 248
@@ -66,34 +66,42 @@
Caption = 'Limpar'
TabOrder = 3
end
- object Button8: TButton
+ object btUp: TButton
Left = 414
Height = 25
Top = 64
Width = 75
- Caption = 'Button1'
+ Caption = 'Up'
TabOrder = 4
end
- object btImprimir: TButton
+ object btPrint: TButton
Left = 21
Height = 25
Top = 297
Width = 75
Anchors = [akLeft, akBottom]
Caption = 'Imprimir...'
- OnClick = btImprimirClick
+ OnClick = btPrintClick
TabOrder = 5
end
- object btIngredientes: TButton
+ object btIngredients: TButton
Left = 134
Height = 25
Top = 296
Width = 154
Anchors = [akLeft, akBottom]
Caption = 'Lista de Ingredientes...'
- OnClick = btIngredientesClick
+ OnClick = btIngredientsClick
TabOrder = 6
end
+ object btRemove: TButton
+ Left = 413
+ Height = 25
+ Top = 128
+ Width = 75
+ Caption = 'Remove'
+ TabOrder = 7
+ end
end
object PrintDialog: TPrintDialog
left = 528
Modified: trunk/u_main.lrt
===================================================================
--- trunk/u_main.lrt 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_main.lrt 2009-12-04 17:49:56 UTC (rev 9)
@@ -2,9 +2,10 @@
TFMMAIN.GBCARDAPIO.CAPTION=Cardápio
TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION=Data
TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION=Pratos
-TFMMAIN.BTNOVA.CAPTION=Nova...
-TFMMAIN.BTCARREMOVER.CAPTION=Remover
-TFMMAIN.BTCARLIMPAR.CAPTION=Limpar
-TFMMAIN.BUTTON8.CAPTION=Button1
-TFMMAIN.BTIMPRIMIR.CAPTION=Imprimir...
-TFMMAIN.BTINGREDIENTES.CAPTION=Lista de Ingredientes...
+TFMMAIN.BTNEW.CAPTION=Nova...
+TFMMAIN.BTDOWN.CAPTION=Down
+TFMMAIN.BTCLEAR.CAPTION=Limpar
+TFMMAIN.BTUP.CAPTION=Up
+TFMMAIN.BTPRINT.CAPTION=Imprimir...
+TFMMAIN.BTINGREDIENTS.CAPTION=Lista de Ingredientes...
+TFMMAIN.BTREMOVE.CAPTION=Remove
Modified: trunk/u_main.pas
===================================================================
--- trunk/u_main.pas 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_main.pas 2009-12-04 17:49:56 UTC (rev 9)
@@ -33,18 +33,19 @@
{ TfmMain }
TfmMain = class(TForm)
- btIngredientes: TButton;
- btNova: TButton;
- btCarRemover: TButton;
- btCarLimpar: TButton;
- Button8: TButton;
- btImprimir: TButton;
+ btIngredients: TButton;
+ btNew: TButton;
+ btDown: TButton;
+ btClear: TButton;
+ btUp: TButton;
+ btPrint: TButton;
+ btRemove: TButton;
gbCardapio: TGroupBox;
PrintDialog: TPrintDialog;
sgCardapio: TStringGrid;
- procedure btImprimirClick(Sender: TObject);
- procedure btIngredientesClick(Sender: TObject);
- procedure btNovaClick(Sender: TObject);
+ procedure btPrintClick(Sender: TObject);
+ procedure btIngredientsClick(Sender: TObject);
+ procedure btNewClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
private
{ private declarations }
@@ -83,7 +84,7 @@
end;
-procedure TfmMain.btImprimirClick(Sender: TObject);
+procedure TfmMain.btPrintClick(Sender: TObject);
begin
if PrintDialog.Execute then
with TStringGridPrinter.Create do
@@ -104,12 +105,12 @@
end;
-procedure TfmMain.btIngredientesClick(Sender: TObject);
+procedure TfmMain.btIngredientsClick(Sender: TObject);
begin
fmIngredients.ShowModal;
end;
-procedure TfmMain.btNovaClick(Sender: TObject);
+procedure TfmMain.btNewClick(Sender: TObject);
begin
fmMeal.ShowModal;
end;
Modified: trunk/u_meal.lfm
===================================================================
--- trunk/u_meal.lfm 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_meal.lfm 2009-12-04 17:49:56 UTC (rev 9)
@@ -9,7 +9,7 @@
OnCreate = FormCreate
OnShow = FormShow
LCLVersion = '0.9.28.2'
- object gbRefeicao: TGroupBox
+ object gbMeal: TGroupBox
Left = 20
Height = 240
Top = 16
@@ -19,25 +19,25 @@
ClientHeight = 222
ClientWidth = 516
TabOrder = 0
- object lbTipo: TLabel
+ object lbType: TLabel
Left = 30
Height = 14
Top = 23
Width = 25
Caption = 'Tipo:'
- FocusControl = cbTipo
+ FocusControl = cbType
ParentColor = False
end
- object lbPrato: TLabel
+ object lbDish: TLabel
Left = 30
Height = 14
Top = 72
Width = 31
Caption = 'Prato:'
- FocusControl = cbPrato
+ FocusControl = cbDish
ParentColor = False
end
- object lblRefeicao: TLabel
+ object lblMeal: TLabel
Left = 238
Height = 14
Top = 24
@@ -45,17 +45,17 @@
Caption = 'Refeição:'
ParentColor = False
end
- object cbTipo: TComboBox
+ object cbType: TComboBox
Left = 30
Height = 21
Top = 40
Width = 152
ItemHeight = 13
- OnChange = cbTipoChange
+ OnChange = cbTypeChange
Style = csDropDownList
TabOrder = 0
end
- object deData: TDateEdit
+ object deDate: TDateEdit
Left = 238
Height = 21
Top = 176
@@ -106,7 +106,7 @@
NumGlyphs = 0
TabOrder = 1
end
- object cbPrato: TComboBox
+ object cbDish: TComboBox
Left = 30
Height = 21
Top = 90
@@ -115,23 +115,23 @@
Style = csDropDownList
TabOrder = 2
end
- object btPrato: TButton
+ object btAddDish: TButton
Left = 107
Height = 25
Top = 127
Width = 75
Caption = 'Adicionar'
- OnClick = btPratoClick
+ OnClick = btAddDishClick
TabOrder = 3
end
- object lbRefeicao: TListBox
+ object lbMeal: TListBox
Left = 238
Height = 112
Top = 40
Width = 152
ItemHeight = 0
MultiSelect = True
- OnClick = lbRefeicaoClick
+ OnClick = lbMealClick
TabOrder = 4
end
object btDown: TButton
@@ -154,54 +154,54 @@
OnClick = btUpClick
TabOrder = 6
end
- object btRemover: TButton
+ object btRemove: TButton
Left = 414
Height = 25
Top = 96
Width = 75
Caption = 'Remover'
Enabled = False
- OnClick = btRemoverClick
+ OnClick = btRemoveClick
TabOrder = 7
end
- object btLimpar: TButton
+ object btClear: TButton
Left = 414
Height = 25
Top = 127
Width = 75
Caption = 'Limpar'
Enabled = False
- OnClick = btLimparClick
+ OnClick = btClearClick
TabOrder = 8
end
end
- object btAdicionar: TButton
+ object btAdd: TButton
Left = 24
Height = 25
Top = 280
Width = 75
Caption = 'Adicionar'
Default = True
- OnClick = btAdicionarClick
+ OnClick = btAddClick
TabOrder = 1
end
- object btAdicionarEFechar: TButton
+ object btAddAndClose: TButton
Left = 128
Height = 25
Top = 280
Width = 107
Caption = 'Adicionar e Fechar'
- OnClick = btAdicionarEFecharClick
+ OnClick = btAddAndCloseClick
TabOrder = 2
end
- object btFechar: TButton
+ object btClose: TButton
Left = 464
Height = 25
Top = 280
Width = 75
Cancel = True
Caption = 'Fechar'
- OnClick = btFecharClick
+ OnClick = btCloseClick
TabOrder = 3
end
end
Modified: trunk/u_meal.lrt
===================================================================
--- trunk/u_meal.lrt 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_meal.lrt 2009-12-04 17:49:56 UTC (rev 9)
@@ -1,16 +1,16 @@
TFMMEAL.CAPTION=fmMeal
-TFMMEAL.GBREFEICAO.CAPTION=Refeição
-TFMMEAL.LBTIPO.CAPTION=Tipo:
-TFMMEAL.LBPRATO.CAPTION=Prato:
-TFMMEAL.LBLREFEICAO.CAPTION=Refeição:
-TFMMEAL.DEDATA.DIALOGTITLE=Escolha a data
-TFMMEAL.DEDATA.OKCAPTION=OK
-TFMMEAL.DEDATA.CANCELCAPTION=Cancelar
-TFMMEAL.BTPRATO.CAPTION=Adicionar
+TFMMEAL.GBMEAL.CAPTION=Refeição
+TFMMEAL.LBTYPE.CAPTION=Tipo:
+TFMMEAL.LBDISH.CAPTION=Prato:
+TFMMEAL.LBLMEAL.CAPTION=Refeição:
+TFMMEAL.DEDATE.DIALOGTITLE=Escolha a data
+TFMMEAL.DEDATE.OKCAPTION=OK
+TFMMEAL.DEDATE.CANCELCAPTION=Cancelar
+TFMMEAL.BTADDDISH.CAPTION=Adicionar
TFMMEAL.BTDOWN.CAPTION=Abaixo
TFMMEAL.BTUP.CAPTION=Acima
-TFMMEAL.BTREMOVER.CAPTION=Remover
-TFMMEAL.BTLIMPAR.CAPTION=Limpar
-TFMMEAL.BTADICIONAR.CAPTION=Adicionar
-TFMMEAL.BTADICIONAREFECHAR.CAPTION=Adicionar e Fechar
-TFMMEAL.BTFECHAR.CAPTION=Fechar
+TFMMEAL.BTREMOVE.CAPTION=Remover
+TFMMEAL.BTCLEAR.CAPTION=Limpar
+TFMMEAL.BTADD.CAPTION=Adicionar
+TFMMEAL.BTADDANDCLOSE.CAPTION=Adicionar e Fechar
+TFMMEAL.BTCLOSE.CAPTION=Fechar
Modified: trunk/u_meal.pas
===================================================================
--- trunk/u_meal.pas 2009-12-04 17:25:30 UTC (rev 8)
+++ trunk/u_meal.pas 2009-12-04 17:49:56 UTC (rev 9)
@@ -33,34 +33,34 @@
{ TfmMeal }
TfmMeal = class(TForm)
- btPrato: TButton;
- btAdicionar: TButton;
- btLimpar: TButton;
- btRemover: TButton;
+ btAddDish: TButton;
+ btAdd: TButton;
+ btClear: TButton;
+ btRemove: TButton;
btDown: TButton;
btUp: TButton;
- btAdicionarEFechar: TButton;
- btFechar: TButton;
- cbPrato: TComboBox;
- cbTipo: TComboBox;
- deData: TDateEdit;
- gbRefeicao: TGroupBox;
- lblRefeicao: TLabel;
- lbPrato: TLabel;
- lbRefeicao: TListBox;
- lbTipo: TLabel;
- procedure btAdicionarClick(Sender: TObject);
- procedure btAdicionarEFecharClick(Sender: TObject);
+ btAddAndClose: TButton;
+ btClose: TButton;
+ cbDish: TComboBox;
+ cbType: TComboBox;
+ deDate: TDateEdit;
+ gbMeal: TGroupBox;
+ lblMeal: TLabel;
+ lbDish: TLabel;
+ lbMeal: TListBox;
+ lbType: TLabel;
+ procedure btAddClick(Sender: TObject);
+ procedure btAddAndCloseClick(Sender: TObject);
procedure btDownClick(Sender: TObject);
- procedure btFecharClick(Sender: TObject);
- procedure btPratoClick(Sender: TObject);
- procedure btLimparClick(Sender: TObject);
- procedure btRemoverClick(Sender: TObject);
+ procedure btCloseClick(Sender: TObject);
+ procedure btAddDishClick(Sender: TObject);
+ procedure btClearClick(Sender: TObject);
+ procedure btRemoveClick(Sender: TObject);
procedure btUpClick(Sender: TObject);
- procedure cbTipoChange(Sender: TObject);
+ procedure cbTypeChange(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure FormShow(Sender: TObject);
- procedure lbRefeicaoClick(Sender: TObject);
+ procedure lbMealClick(Sender: TObject);
private
{ private declarations }
procedure UpdateRefeicao;
@@ -81,30 +81,30 @@
procedure TfmMeal.FormCreate(Sender: TObject);
begin
- cbTipo.Items.Assign(Pratos.TodosTipos);
+ cbType.Items.Assign(Pratos.TodosTipos);
end;
procedure TfmMeal.FormShow(Sender: TObject);
begin
- cbTipo.ItemIndex:= 0;
- cbTipoChange(Sender); // já que alterar o ItemIndex não dispara esse evento...
+ cbType.ItemIndex:= 0;
+ cbTypeChange(Sender); // já que alterar o ItemIndex não dispara esse evento...
UpdateRefeicao;
end;
-procedure TfmMeal.cbTipoChange(Sender: TObject);
+procedure TfmMeal.cbTypeChange(Sender: TObject);
begin
- cbPrato.Items.Assign(Pratos.PratosPorTipo(cbTipo.Items[cbTipo.ItemIndex]).TodosPratos);
- cbPrato.ItemIndex:= 0;
+ cbDish.Items.Assign(Pratos.PratosPorTipo(cbType.Items[cbType.ItemIndex]).TodosPratos);
+ cbDish.ItemIndex:= 0;
end;
-procedure TfmMeal.btAdicionarClick(Sender: TObject);
+procedure TfmMeal.btAddClick(Sender: TObject);
begin
if not Adicionar then
ShowMessage(sError);
end;
-procedure TfmMeal.btAdicionarEFecharClick(Sender: TObject);
+procedure TfmMeal.btAddAndCloseClick(Sender: TObject);
begin
if not Adicionar then
ShowMessage(sError)
@@ -116,36 +116,36 @@
var
i: Integer;
begin
- for i:= (lbRefeicao.Count-2) downto 0 do
- if lbRefeicao.Selected[i] then
- lbRefeicao.Items.Exchange(i, i+1); //TODO: não está funcionando a contento: é necessário trocar os selecionados
+ for i:= (lbMeal.Count-2) downto 0 do
+ if lbMeal.Selected[i] then
+ lbMeal.Items.Exchange(i, i+1); //TODO: não está funcionando a contento: é necessário trocar os selecionados
end;
-procedure TfmMeal.btFecharClick(Sender: TObject);
+procedure TfmMeal.btCloseClick(Sender: TObject);
begin
- lbRefeicao.Clear;
+ lbMeal.Clear;
Close;
end;
-procedure TfmMeal.btPratoClick(Sender: TObject);
+procedure TfmMeal.btAddDishClick(Sender: TObject);
begin
- lbRefeicao.Items.Add(cbPrato.Items.Strings[cbPrato.ItemIndex]);
+ lbMeal.Items.Add(cbDish.Items.Strings[cbDish.ItemIndex]);
UpdateRefeicao;
end;
-procedure TfmMeal.btLimparClick(Sender: TObject);
+procedure TfmMeal.btClearClick(Sender: TObject);
begin
- lbRefeicao.Clear;
+ lbMeal.Clear;
UpdateRefeicao;
end;
-procedure TfmMeal.btRemoverClick(Sender: TObject);
+procedure TfmMeal.btRemoveClick(Sender: TObject);
var
i: Integer;
begin
- for i:= (lbRefeicao.Count-1) downto 0 do
- if lbRefeicao.Selected[i] then
- lbRefeicao.Items.Delete(i);
+ for i:= (lbMeal.Count-1) downto 0 do
+ if lbMeal.Selected[i] then
+ lbMeal.Items.Delete(i);
UpdateRefeicao;
end;
@@ -156,19 +156,19 @@
end;
-procedure TfmMeal.lbRefeicaoClick(Sender: TObject);
+procedure TfmMeal.lbMealClick(Sender: TObject);
begin
UpdateRefeicao;
end;
procedure TfmMeal.UpdateRefeicao;
begin
- btUp.Enabled:= ((lbRefeicao.SelCount > 0) and (not lbRefeicao.Selected[0]));
- btDown.Enabled:= ((lbRefeicao.SelCount > 0) and (not lbRefeicao.Selected[lbRefeicao.Count-1]));
- btRemover.Enabled:= (lbRefeicao.SelCount > 0);
- btLimpar.Enabled:= (lbRefeicao.Count > 0);
- btAdicionar.Enabled:= (lbRefeicao.Items.Count > 0);
- btAdicionarEFechar.Enabled:= btAdicionar.Enabled;
+ btUp.Enabled:= ((lbMeal.SelCount > 0) and (not lbMeal.Selected[0]));
+ btDown.Enabled:= ((lbMeal.SelCount > 0) and (not lbMeal.Selected[lbMeal.Count-1]));
+ btRemove.Enabled:= (lbMeal.SelCount > 0);
+ btClear.Enabled:= (lbMeal.Count > 0);
+ btAdd.Enabled:= (lbMeal.Items.Count > 0);
+ btAddAndClose.Enabled:= btAdd.Enabled;
end;
function TfmMeal.Adicionar: Boolean;
@@ -179,15 +179,15 @@
Result:= False;
Refeicao:= TRefeicao.Create;
try
- for i:= 0 to (lbRefeicao.Count-1) do
+ for i:= 0 to (lbMeal.Count-1) do
begin
- Refeicao.AdicionaPrato(Pratos.PratoPorNome(lbRefeicao.Items.Strings[i]));
+ Refeicao.AdicionaPrato(Pratos.PratoPorNome(lbMeal.Items.Strings[i]));
end;
- Refeicao.Data:= deData.Date;
+ Refeicao.Data:= deDate.Date;
//TODO: falta adicionar ao cardápio
- lbRefeicao.Clear;
+ lbMeal.Clear;
UpdateRefeicao;
except
Result:= False;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-12-04 17:25:39
|
Revision: 8
http://gotisso.svn.sourceforge.net/gotisso/?rev=8&view=rev
Author: jmvaz
Date: 2009-12-04 17:25:30 +0000 (Fri, 04 Dec 2009)
Log Message:
-----------
program output dir changed
Modified Paths:
--------------
trunk/gotisso.lpi
Modified: trunk/gotisso.lpi
===================================================================
--- trunk/gotisso.lpi 2009-11-04 01:08:04 UTC (rev 7)
+++ trunk/gotisso.lpi 2009-12-04 17:25:30 UTC (rev 8)
@@ -89,7 +89,7 @@
<PathDelim Value="\"/>
<SearchPaths>
<IncludeFiles Value="$(ProjOutDir)\"/>
- <UnitOutputDirectory Value="..\..\output"/>
+ <UnitOutputDirectory Value="\output"/>
</SearchPaths>
<Parsing>
<SyntaxOptions>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-11-04 01:08:11
|
Revision: 7
http://gotisso.svn.sourceforge.net/gotisso/?rev=7&view=rev
Author: jmvaz
Date: 2009-11-04 01:08:04 +0000 (Wed, 04 Nov 2009)
Log Message:
-----------
add personal session info gotisso.lps to ignore list
Removed Paths:
-------------
trunk/gotisso.lps
Property Changed:
----------------
trunk/
Property changes on: trunk
___________________________________________________________________
Added: svn:ignore
+ *.lps
Deleted: trunk/gotisso.lps
===================================================================
--- trunk/gotisso.lps 2009-11-04 00:33:09 UTC (rev 6)
+++ trunk/gotisso.lps 2009-11-04 01:08:04 UTC (rev 7)
@@ -1,378 +0,0 @@
-<?xml version="1.0"?>
-<CONFIG>
- <ProjectSession>
- <PathDelim Value="\"/>
- <Version Value="7"/>
- <Units Count="47">
- <Unit0>
- <Filename Value="gotisso.lpr"/>
- <IsPartOfProject Value="True"/>
- <UnitName Value="gotisso"/>
- <CursorPos X="2" Y="7"/>
- <TopLine Value="1"/>
- <EditorIndex Value="0"/>
- <UsageCount Value="63"/>
- <Loaded Value="True"/>
- <SyntaxHighlighter Value="Delphi"/>
- </Unit0>
- <Unit1>
- <Filename Value="u_main.pas"/>
- <IsPartOfProject Value="True"/>
- <ComponentName Value="fmMain"/>
- <ResourceBaseClass Value="Form"/>
- <UnitName Value="u_main"/>
- <CursorPos X="9" Y="114"/>
- <TopLine Value="84"/>
- <EditorIndex Value="1"/>
- <UsageCount Value="63"/>
- <Loaded Value="True"/>
- <SyntaxHighlighter Value="Delphi"/>
- </Unit1>
- <Unit2>
- <Filename Value="u_ingredients.pas"/>
- <IsPartOfProject Value="True"/>
- <ComponentName Value="fmIngredients"/>
- <ResourceBaseClass Value="Form"/>
- <UnitName Value="u_ingredients"/>
- <CursorPos X="1" Y="21"/>
- <TopLine Value="1"/>
- <EditorIndex Value="3"/>
- <UsageCount Value="61"/>
- <Loaded Value="True"/>
- <SyntaxHighlighter Value="Delphi"/>
- </Unit2>
- <Unit3>
- <Filename Value="stringgridprinter.pas"/>
- <IsPartOfProject Value="True"/>
- <UnitName Value="StringGridPrinter"/>
- <CursorPos X="62" Y="8"/>
- <TopLine Value="1"/>
- <EditorIndex Value="6"/>
- <UsageCount Value="60"/>
- <Loaded Value="True"/>
- <SyntaxHighlighter Value="Delphi"/>
- </Unit3>
- <Unit4>
- <Filename Value="u_consts.pas"/>
- <IsPartOfProject Value="True"/>
- <UnitName Value="u_consts"/>
- <CursorPos X="1" Y="21"/>
- <TopLine Value="1"/>
- <EditorIndex Value="5"/>
- <UsageCount Value="56"/>
- <Loaded Value="True"/>
- <SyntaxHighlighter Value="Delphi"/>
- </Unit4>
- <Unit5>
- <Filename Value="u_classes.pas"/>
- <IsPartOfProject Value="True"/>
- <UnitName Value="u_classes"/>
- <CursorPos X="1" Y="21"/>
- <TopLine Value="1"/>
- <EditorIndex Value="4"/>
- <UsageCount Value="52"/>
- <Loaded Value="True"/>
- <SyntaxHighlighter Value="Delphi"/>
- </Unit5>
- <Unit6>
- <Filename Value="u_meal.pas"/>
- <IsPartOfProject Value="True"/>
- <ComponentName Value="fmMeal"/>
- <ResourceBaseClass Value="Form"/>
- <UnitName Value="u_meal"/>
- <CursorPos X="1" Y="21"/>
- <TopLine Value="1"/>
- <EditorIndex Value="2"/>
- <UsageCount Value="29"/>
- <Loaded Value="True"/>
- <SyntaxHighlighter Value="Delphi"/>
- </Unit6>
- <Unit7>
- <Filename Value="C:\Develop\lazarus\components\printers\printersdlgs.pp"/>
- <UnitName Value="PrintersDlgs"/>
- <CursorPos X="31" Y="56"/>
- <TopLine Value="88"/>
- <UsageCount Value="8"/>
- </Unit7>
- <Unit8>
- <Filename Value="C:\Develop\lazarus\lcl\dialogs.pp"/>
- <UnitName Value="Dialogs"/>
- <CursorPos X="3" Y="439"/>
- <TopLine Value="511"/>
- <UsageCount Value="8"/>
- </Unit8>
- <Unit9>
- <Filename Value="C:\Develop\lazarus\languages\README.txt"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="1"/>
- <UsageCount Value="8"/>
- <SyntaxHighlighter Value="None"/>
- </Unit9>
- <Unit10>
- <Filename Value="C:\Develop\lazarus\lcl\defaulttranslator.pas"/>
- <UnitName Value="DefaultTranslator"/>
- <CursorPos X="16" Y="170"/>
- <TopLine Value="132"/>
- <UsageCount Value="9"/>
- </Unit10>
- <Unit11>
- <Filename Value="C:\Develop\lazarus\lcl\lresources.pp"/>
- <UnitName Value="LResources"/>
- <CursorPos X="27" Y="105"/>
- <TopLine Value="79"/>
- <UsageCount Value="9"/>
- </Unit11>
- <Unit12>
- <Filename Value="C:\Develop\lazarus\lcl\interfaces\win32\interfaces.pp"/>
- <UnitName Value="Interfaces"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="1"/>
- <UsageCount Value="8"/>
- </Unit12>
- <Unit13>
- <Filename Value="C:\Develop\lazarus\fpc\2.2.2\source\packages\fcl-base\src\gettext.pp"/>
- <UnitName Value="gettext"/>
- <CursorPos X="35" Y="91"/>
- <TopLine Value="221"/>
- <UsageCount Value="8"/>
- </Unit13>
- <Unit14>
- <Filename Value="D:\lazarus\lcl\printers.pas"/>
- <UnitName Value="Printers"/>
- <CursorPos X="30" Y="176"/>
- <TopLine Value="160"/>
- <UsageCount Value="9"/>
- </Unit14>
- <Unit15>
- <Filename Value="D:\lazarus\components\printers\printer4lazarus.pas"/>
- <UnitName Value="Printer4Lazarus"/>
- <CursorPos X="21" Y="10"/>
- <TopLine Value="1"/>
- <UsageCount Value="9"/>
- </Unit15>
- <Unit16>
- <Filename Value="D:\lazarus\components\printers\osprinters.pas"/>
- <UnitName Value="OSPrinters"/>
- <CursorPos X="13" Y="84"/>
- <TopLine Value="52"/>
- <UsageCount Value="8"/>
- </Unit16>
- <Unit17>
- <Filename Value="D:\lazarus\components\printers\win32\winprinters_h.inc"/>
- <CursorPos X="103" Y="73"/>
- <TopLine Value="53"/>
- <UsageCount Value="8"/>
- </Unit17>
- <Unit18>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win32\windows.pp"/>
- <UnitName Value="windows"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="32"/>
- <UsageCount Value="8"/>
- </Unit18>
- <Unit19>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win\wininc\struct.inc"/>
- <CursorPos X="13" Y="4936"/>
- <TopLine Value="4918"/>
- <UsageCount Value="8"/>
- </Unit19>
- <Unit20>
- <Filename Value="D:\lazarus\components\printers\printersdlgs.pp"/>
- <UnitName Value="PrintersDlgs"/>
- <CursorPos X="32" Y="118"/>
- <TopLine Value="90"/>
- <UsageCount Value="8"/>
- </Unit20>
- <Unit21>
- <Filename Value="D:\lazarus\components\printers\win32\winprndialogs.inc"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="270"/>
- <UsageCount Value="8"/>
- </Unit21>
- <Unit22>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\packages\winunits-base\src\winver.pp"/>
- <UnitName Value="winver"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="13"/>
- <UsageCount Value="8"/>
- </Unit22>
- <Unit23>
- <Filename Value="D:\lazarus\components\printers\win32\winprinters.inc"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="806"/>
- <UsageCount Value="8"/>
- </Unit23>
- <Unit24>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win\wininc\redef.inc"/>
- <CursorPos X="24" Y="619"/>
- <TopLine Value="601"/>
- <UsageCount Value="8"/>
- </Unit24>
- <Unit25>
- <Filename Value="D:\lazarus\lcl\forms.pp"/>
- <UnitName Value="Forms"/>
- <CursorPos X="30" Y="830"/>
- <TopLine Value="826"/>
- <UsageCount Value="8"/>
- </Unit25>
- <Unit26>
- <Filename Value="D:\lazarus\lcl\lclclasses.pp"/>
- <UnitName Value="LCLClasses"/>
- <CursorPos X="3" Y="38"/>
- <TopLine Value="32"/>
- <UsageCount Value="8"/>
- </Unit26>
- <Unit27>
- <Filename Value="D:\lazarus\lcl\graphics.pp"/>
- <UnitName Value="Graphics"/>
- <CursorPos X="8" Y="67"/>
- <TopLine Value="47"/>
- <UsageCount Value="8"/>
- </Unit27>
- <Unit28>
- <Filename Value="D:\lazarus\lcl\lcltype.pp"/>
- <UnitName Value="LCLType"/>
- <CursorPos X="3" Y="863"/>
- <TopLine Value="845"/>
- <UsageCount Value="8"/>
- </Unit28>
- <Unit29>
- <Filename Value="C:\Develop\lazarus\lcl\lcltype.pp"/>
- <UnitName Value="LCLType"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="52"/>
- <UsageCount Value="8"/>
- </Unit29>
- <Unit30>
- <Filename Value="C:\Develop\lazarus\fpc\2.2.4\source\rtl\win\wininc\struct.inc"/>
- <CursorPos X="6" Y="4936"/>
- <TopLine Value="4926"/>
- <UsageCount Value="8"/>
- </Unit30>
- <Unit31>
- <Filename Value="C:\Develop\lazarus\lcl\include\winapih.inc"/>
- <CursorPos X="38" Y="4"/>
- <TopLine Value="1"/>
- <UsageCount Value="8"/>
- </Unit31>
- <Unit32>
- <Filename Value="C:\Develop\lazarus\lcl\lclintf.pas"/>
- <UnitName Value="LCLIntf"/>
- <CursorPos X="1" Y="1"/>
- <TopLine Value="4"/>
- <UsageCount Value="8"/>
- </Unit32>
- <Unit33>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\classes\classesh.inc"/>
- <CursorPos X="19" Y="364"/>
- <TopLine Value="343"/>
- <UsageCount Value="18"/>
- </Unit33>
- <Unit34>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win32\classes.pp"/>
- <UnitName Value="Classes"/>
- <CursorPos X="7" Y="28"/>
- <TopLine Value="10"/>
- <UsageCount Value="11"/>
- </Unit34>
- <Unit35>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\types.pp"/>
- <UnitName Value="types"/>
- <CursorPos X="27" Y="120"/>
- <TopLine Value="102"/>
- <UsageCount Value="11"/>
- </Unit35>
- <Unit36>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\inc\objpash.inc"/>
- <CursorPos X="22" Y="153"/>
- <TopLine Value="135"/>
- <UsageCount Value="10"/>
- </Unit36>
- <Unit37>
- <Filename Value="D:\lazarus\lcl\include\customcombobox.inc"/>
- <CursorPos X="51" Y="939"/>
- <TopLine Value="920"/>
- <UsageCount Value="9"/>
- </Unit37>
- <Unit38>
- <Filename Value="D:\lazarus\lcl\stdctrls.pp"/>
- <UnitName Value="StdCtrls"/>
- <CursorPos X="24" Y="569"/>
- <TopLine Value="551"/>
- <UsageCount Value="10"/>
- </Unit38>
- <Unit39>
- <Filename Value="D:\lazarus\lcl\widgetset\wsstdctrls.pp"/>
- <UnitName Value="WSStdCtrls"/>
- <CursorPos X="1" Y="407"/>
- <TopLine Value="5"/>
- <UsageCount Value="9"/>
- </Unit39>
- <Unit40>
- <Filename Value="D:\lazarus\lcl\include\customlistbox.inc"/>
- <CursorPos X="1" Y="598"/>
- <TopLine Value="580"/>
- <UsageCount Value="10"/>
- </Unit40>
- <Unit41>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\inc\wstringh.inc"/>
- <CursorPos X="11" Y="30"/>
- <TopLine Value="12"/>
- <UsageCount Value="10"/>
- </Unit41>
- <Unit42>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\classes\stringl.inc"/>
- <CursorPos X="3" Y="392"/>
- <TopLine Value="392"/>
- <UsageCount Value="10"/>
- </Unit42>
- <Unit43>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\classes\persist.inc"/>
- <CursorPos X="82" Y="35"/>
- <TopLine Value="35"/>
- <UsageCount Value="10"/>
- </Unit43>
- <Unit44>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\inc\systemh.inc"/>
- <CursorPos X="11" Y="664"/>
- <TopLine Value="646"/>
- <UsageCount Value="10"/>
- </Unit44>
- <Unit45>
- <Filename Value="D:\lazarus\lcl\interfaces\win32\win32listsl.inc"/>
- <CursorPos X="1" Y="206"/>
- <TopLine Value="188"/>
- <UsageCount Value="10"/>
- </Unit45>
- <Unit46>
- <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\rtlconst.inc"/>
- <CursorPos X="3" Y="34"/>
- <TopLine Value="16"/>
- <UsageCount Value="10"/>
- </Unit46>
- </Units>
- <General>
- <ActiveEditorIndexAtStart Value="1"/>
- </General>
- <JumpHistory Count="2" HistoryIndex="1">
- <Position1>
- <Filename Value="u_meal.pas"/>
- <Caret Line="92" Column="5" TopLine="1"/>
- </Position1>
- <Position2>
- <Filename Value="u_main.pas"/>
- <Caret Line="2" Column="9" TopLine="1"/>
- </Position2>
- </JumpHistory>
- </ProjectSession>
- <Debugging>
- <Exceptions Count="2">
- <Item1>
- <Name Value="ECodetoolError"/>
- </Item1>
- <Item2>
- <Name Value="EFOpenError"/>
- </Item2>
- </Exceptions>
- </Debugging>
-</CONFIG>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-11-04 00:33:19
|
Revision: 6
http://gotisso.svn.sourceforge.net/gotisso/?rev=6&view=rev
Author: jmvaz
Date: 2009-11-04 00:33:09 +0000 (Wed, 04 Nov 2009)
Log Message:
-----------
initial commit
Added Paths:
-----------
documentation/doc.txt
trunk/backup/
trunk/gotisso.lpi
trunk/gotisso.lpr
trunk/gotisso.lps
trunk/gotisso.manifest
trunk/gotisso.rc
trunk/lang/
trunk/lang/gotisso.po
trunk/stringgridprinter.pas
trunk/u_classes.pas
trunk/u_consts.pas
trunk/u_ingredients.lfm
trunk/u_ingredients.lrt
trunk/u_ingredients.pas
trunk/u_main.lfm
trunk/u_main.lrt
trunk/u_main.pas
trunk/u_meal.lfm
trunk/u_meal.lrt
trunk/u_meal.pas
Added: documentation/doc.txt
===================================================================
--- documentation/doc.txt (rev 0)
+++ documentation/doc.txt 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,9 @@
+Program name:
+
+1. Menu du Jour
+2. Vapt Cook
+3. Gotisso
+
+Mission:
+
+With Gotisso you can plan your meals, generating shopping lists to help your domestic tasks. Future plans include a recipe manager.
Added: trunk/gotisso.lpi
===================================================================
--- trunk/gotisso.lpi (rev 0)
+++ trunk/gotisso.lpi 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,130 @@
+<?xml version="1.0"?>
+<CONFIG>
+ <ProjectOptions>
+ <PathDelim Value="\"/>
+ <Version Value="7"/>
+ <General>
+ <SessionStorage Value="InProjectDir"/>
+ <MainUnit Value="0"/>
+ <TargetFileExt Value=".exe"/>
+ <Title Value="gotisso"/>
+ <UseAppBundle Value="False"/>
+ <UseXPManifest Value="True"/>
+ </General>
+ <i18n>
+ <EnableI18N Value="True"/>
+ <OutDir Value="lang"/>
+ </i18n>
+ <VersionInfo>
+ <ProjectVersion Value="0.0.0.0"/>
+ <Language Value="0416"/>
+ </VersionInfo>
+ <PublishOptions>
+ <Version Value="2"/>
+ <IgnoreBinaries Value="False"/>
+ <IncludeFileFilter Value="*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml)"/>
+ <ExcludeFileFilter Value="*.(bak|ppu|ppw|o|so);*~;backup"/>
+ </PublishOptions>
+ <RunParams>
+ <local>
+ <FormatVersion Value="1"/>
+ <LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
+ </local>
+ </RunParams>
+ <RequiredPackages Count="2">
+ <Item1>
+ <PackageName Value="Printer4Lazarus"/>
+ <MinVersion Minor="5" Valid="True"/>
+ </Item1>
+ <Item2>
+ <PackageName Value="LCL"/>
+ </Item2>
+ </RequiredPackages>
+ <Units Count="7">
+ <Unit0>
+ <Filename Value="gotisso.lpr"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="gotisso"/>
+ </Unit0>
+ <Unit1>
+ <Filename Value="u_main.pas"/>
+ <IsPartOfProject Value="True"/>
+ <ComponentName Value="fmMain"/>
+ <ResourceBaseClass Value="Form"/>
+ <UnitName Value="u_main"/>
+ </Unit1>
+ <Unit2>
+ <Filename Value="u_ingredients.pas"/>
+ <IsPartOfProject Value="True"/>
+ <ComponentName Value="fmIngredients"/>
+ <ResourceBaseClass Value="Form"/>
+ <UnitName Value="u_ingredients"/>
+ </Unit2>
+ <Unit3>
+ <Filename Value="stringgridprinter.pas"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="StringGridPrinter"/>
+ </Unit3>
+ <Unit4>
+ <Filename Value="u_consts.pas"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="u_consts"/>
+ </Unit4>
+ <Unit5>
+ <Filename Value="u_classes.pas"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="u_classes"/>
+ </Unit5>
+ <Unit6>
+ <Filename Value="u_meal.pas"/>
+ <IsPartOfProject Value="True"/>
+ <ComponentName Value="fmMeal"/>
+ <ResourceBaseClass Value="Form"/>
+ <UnitName Value="u_meal"/>
+ </Unit6>
+ </Units>
+ </ProjectOptions>
+ <CompilerOptions>
+ <Version Value="8"/>
+ <PathDelim Value="\"/>
+ <SearchPaths>
+ <IncludeFiles Value="$(ProjOutDir)\"/>
+ <UnitOutputDirectory Value="..\..\output"/>
+ </SearchPaths>
+ <Parsing>
+ <SyntaxOptions>
+ <SyntaxMode Value="Delphi"/>
+ <CStyleOperator Value="False"/>
+ <AllowLabel Value="False"/>
+ </SyntaxOptions>
+ </Parsing>
+ <CodeGeneration>
+ <SmartLinkUnit Value="True"/>
+ <Checks>
+ <IOChecks Value="True"/>
+ <RangeChecks Value="True"/>
+ <OverflowChecks Value="True"/>
+ <StackChecks Value="True"/>
+ </Checks>
+ <VerifyObjMethodCallValidity Value="True"/>
+ </CodeGeneration>
+ <Linking>
+ <Debugging>
+ <GenerateDebugInfo Value="True"/>
+ </Debugging>
+ <LinkSmart Value="True"/>
+ <Options>
+ <Win32>
+ <GraphicApplication Value="True"/>
+ </Win32>
+ </Options>
+ </Linking>
+ <Other>
+ <Verbosity>
+ <ShoLineNum Value="True"/>
+ </Verbosity>
+ <CompilerPath Value="$(CompPath)"/>
+ <CreateMakefileOnBuild Value="True"/>
+ </Other>
+ </CompilerOptions>
+</CONFIG>
Added: trunk/gotisso.lpr
===================================================================
--- trunk/gotisso.lpr (rev 0)
+++ trunk/gotisso.lpr 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,45 @@
+{
+ Copyright (C) 2009 João Marcelo S. Vaz
+
+ This file is part of Gotisso Meal Planner.
+
+ Gotisso Meal Planner is free software: you can redistribute it and/or
+ modify it under the terms of the GNU General Public License as published
+ by the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ Gotisso Meal Planner is distributed in the hope that it will be
+ useful, but WITHOUT ANY WARRANTY; without even the implied warranty
+ of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+}
+program gotisso;
+
+{$mode objfpc}{$H+}
+
+uses
+ {$IFDEF UNIX}
+ {$IFDEF UseCThreads}
+ cthreads,
+ {$ENDIF}
+ {$ENDIF}
+ Interfaces, // this includes the LCL widgetset
+ Forms
+ { you can add units after this },
+ u_main, Printer4Lazarus, u_ingredients, u_consts, u_classes, u_meal;
+
+{$IFDEF WINDOWS}{$R gotisso.rc}{$ENDIF}
+
+begin
+ Application.Title:= sTitle;
+ Application.Initialize;
+ Application.CreateForm(TfmMain, fmMain);
+ Application.CreateForm(TfmIngredients, fmIngredients);
+ Application.CreateForm(TfmMeal, fmMeal);
+ Application.Run;
+end.
+
Added: trunk/gotisso.lps
===================================================================
--- trunk/gotisso.lps (rev 0)
+++ trunk/gotisso.lps 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,378 @@
+<?xml version="1.0"?>
+<CONFIG>
+ <ProjectSession>
+ <PathDelim Value="\"/>
+ <Version Value="7"/>
+ <Units Count="47">
+ <Unit0>
+ <Filename Value="gotisso.lpr"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="gotisso"/>
+ <CursorPos X="2" Y="7"/>
+ <TopLine Value="1"/>
+ <EditorIndex Value="0"/>
+ <UsageCount Value="63"/>
+ <Loaded Value="True"/>
+ <SyntaxHighlighter Value="Delphi"/>
+ </Unit0>
+ <Unit1>
+ <Filename Value="u_main.pas"/>
+ <IsPartOfProject Value="True"/>
+ <ComponentName Value="fmMain"/>
+ <ResourceBaseClass Value="Form"/>
+ <UnitName Value="u_main"/>
+ <CursorPos X="9" Y="114"/>
+ <TopLine Value="84"/>
+ <EditorIndex Value="1"/>
+ <UsageCount Value="63"/>
+ <Loaded Value="True"/>
+ <SyntaxHighlighter Value="Delphi"/>
+ </Unit1>
+ <Unit2>
+ <Filename Value="u_ingredients.pas"/>
+ <IsPartOfProject Value="True"/>
+ <ComponentName Value="fmIngredients"/>
+ <ResourceBaseClass Value="Form"/>
+ <UnitName Value="u_ingredients"/>
+ <CursorPos X="1" Y="21"/>
+ <TopLine Value="1"/>
+ <EditorIndex Value="3"/>
+ <UsageCount Value="61"/>
+ <Loaded Value="True"/>
+ <SyntaxHighlighter Value="Delphi"/>
+ </Unit2>
+ <Unit3>
+ <Filename Value="stringgridprinter.pas"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="StringGridPrinter"/>
+ <CursorPos X="62" Y="8"/>
+ <TopLine Value="1"/>
+ <EditorIndex Value="6"/>
+ <UsageCount Value="60"/>
+ <Loaded Value="True"/>
+ <SyntaxHighlighter Value="Delphi"/>
+ </Unit3>
+ <Unit4>
+ <Filename Value="u_consts.pas"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="u_consts"/>
+ <CursorPos X="1" Y="21"/>
+ <TopLine Value="1"/>
+ <EditorIndex Value="5"/>
+ <UsageCount Value="56"/>
+ <Loaded Value="True"/>
+ <SyntaxHighlighter Value="Delphi"/>
+ </Unit4>
+ <Unit5>
+ <Filename Value="u_classes.pas"/>
+ <IsPartOfProject Value="True"/>
+ <UnitName Value="u_classes"/>
+ <CursorPos X="1" Y="21"/>
+ <TopLine Value="1"/>
+ <EditorIndex Value="4"/>
+ <UsageCount Value="52"/>
+ <Loaded Value="True"/>
+ <SyntaxHighlighter Value="Delphi"/>
+ </Unit5>
+ <Unit6>
+ <Filename Value="u_meal.pas"/>
+ <IsPartOfProject Value="True"/>
+ <ComponentName Value="fmMeal"/>
+ <ResourceBaseClass Value="Form"/>
+ <UnitName Value="u_meal"/>
+ <CursorPos X="1" Y="21"/>
+ <TopLine Value="1"/>
+ <EditorIndex Value="2"/>
+ <UsageCount Value="29"/>
+ <Loaded Value="True"/>
+ <SyntaxHighlighter Value="Delphi"/>
+ </Unit6>
+ <Unit7>
+ <Filename Value="C:\Develop\lazarus\components\printers\printersdlgs.pp"/>
+ <UnitName Value="PrintersDlgs"/>
+ <CursorPos X="31" Y="56"/>
+ <TopLine Value="88"/>
+ <UsageCount Value="8"/>
+ </Unit7>
+ <Unit8>
+ <Filename Value="C:\Develop\lazarus\lcl\dialogs.pp"/>
+ <UnitName Value="Dialogs"/>
+ <CursorPos X="3" Y="439"/>
+ <TopLine Value="511"/>
+ <UsageCount Value="8"/>
+ </Unit8>
+ <Unit9>
+ <Filename Value="C:\Develop\lazarus\languages\README.txt"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="1"/>
+ <UsageCount Value="8"/>
+ <SyntaxHighlighter Value="None"/>
+ </Unit9>
+ <Unit10>
+ <Filename Value="C:\Develop\lazarus\lcl\defaulttranslator.pas"/>
+ <UnitName Value="DefaultTranslator"/>
+ <CursorPos X="16" Y="170"/>
+ <TopLine Value="132"/>
+ <UsageCount Value="9"/>
+ </Unit10>
+ <Unit11>
+ <Filename Value="C:\Develop\lazarus\lcl\lresources.pp"/>
+ <UnitName Value="LResources"/>
+ <CursorPos X="27" Y="105"/>
+ <TopLine Value="79"/>
+ <UsageCount Value="9"/>
+ </Unit11>
+ <Unit12>
+ <Filename Value="C:\Develop\lazarus\lcl\interfaces\win32\interfaces.pp"/>
+ <UnitName Value="Interfaces"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="1"/>
+ <UsageCount Value="8"/>
+ </Unit12>
+ <Unit13>
+ <Filename Value="C:\Develop\lazarus\fpc\2.2.2\source\packages\fcl-base\src\gettext.pp"/>
+ <UnitName Value="gettext"/>
+ <CursorPos X="35" Y="91"/>
+ <TopLine Value="221"/>
+ <UsageCount Value="8"/>
+ </Unit13>
+ <Unit14>
+ <Filename Value="D:\lazarus\lcl\printers.pas"/>
+ <UnitName Value="Printers"/>
+ <CursorPos X="30" Y="176"/>
+ <TopLine Value="160"/>
+ <UsageCount Value="9"/>
+ </Unit14>
+ <Unit15>
+ <Filename Value="D:\lazarus\components\printers\printer4lazarus.pas"/>
+ <UnitName Value="Printer4Lazarus"/>
+ <CursorPos X="21" Y="10"/>
+ <TopLine Value="1"/>
+ <UsageCount Value="9"/>
+ </Unit15>
+ <Unit16>
+ <Filename Value="D:\lazarus\components\printers\osprinters.pas"/>
+ <UnitName Value="OSPrinters"/>
+ <CursorPos X="13" Y="84"/>
+ <TopLine Value="52"/>
+ <UsageCount Value="8"/>
+ </Unit16>
+ <Unit17>
+ <Filename Value="D:\lazarus\components\printers\win32\winprinters_h.inc"/>
+ <CursorPos X="103" Y="73"/>
+ <TopLine Value="53"/>
+ <UsageCount Value="8"/>
+ </Unit17>
+ <Unit18>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win32\windows.pp"/>
+ <UnitName Value="windows"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="32"/>
+ <UsageCount Value="8"/>
+ </Unit18>
+ <Unit19>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win\wininc\struct.inc"/>
+ <CursorPos X="13" Y="4936"/>
+ <TopLine Value="4918"/>
+ <UsageCount Value="8"/>
+ </Unit19>
+ <Unit20>
+ <Filename Value="D:\lazarus\components\printers\printersdlgs.pp"/>
+ <UnitName Value="PrintersDlgs"/>
+ <CursorPos X="32" Y="118"/>
+ <TopLine Value="90"/>
+ <UsageCount Value="8"/>
+ </Unit20>
+ <Unit21>
+ <Filename Value="D:\lazarus\components\printers\win32\winprndialogs.inc"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="270"/>
+ <UsageCount Value="8"/>
+ </Unit21>
+ <Unit22>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\packages\winunits-base\src\winver.pp"/>
+ <UnitName Value="winver"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="13"/>
+ <UsageCount Value="8"/>
+ </Unit22>
+ <Unit23>
+ <Filename Value="D:\lazarus\components\printers\win32\winprinters.inc"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="806"/>
+ <UsageCount Value="8"/>
+ </Unit23>
+ <Unit24>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win\wininc\redef.inc"/>
+ <CursorPos X="24" Y="619"/>
+ <TopLine Value="601"/>
+ <UsageCount Value="8"/>
+ </Unit24>
+ <Unit25>
+ <Filename Value="D:\lazarus\lcl\forms.pp"/>
+ <UnitName Value="Forms"/>
+ <CursorPos X="30" Y="830"/>
+ <TopLine Value="826"/>
+ <UsageCount Value="8"/>
+ </Unit25>
+ <Unit26>
+ <Filename Value="D:\lazarus\lcl\lclclasses.pp"/>
+ <UnitName Value="LCLClasses"/>
+ <CursorPos X="3" Y="38"/>
+ <TopLine Value="32"/>
+ <UsageCount Value="8"/>
+ </Unit26>
+ <Unit27>
+ <Filename Value="D:\lazarus\lcl\graphics.pp"/>
+ <UnitName Value="Graphics"/>
+ <CursorPos X="8" Y="67"/>
+ <TopLine Value="47"/>
+ <UsageCount Value="8"/>
+ </Unit27>
+ <Unit28>
+ <Filename Value="D:\lazarus\lcl\lcltype.pp"/>
+ <UnitName Value="LCLType"/>
+ <CursorPos X="3" Y="863"/>
+ <TopLine Value="845"/>
+ <UsageCount Value="8"/>
+ </Unit28>
+ <Unit29>
+ <Filename Value="C:\Develop\lazarus\lcl\lcltype.pp"/>
+ <UnitName Value="LCLType"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="52"/>
+ <UsageCount Value="8"/>
+ </Unit29>
+ <Unit30>
+ <Filename Value="C:\Develop\lazarus\fpc\2.2.4\source\rtl\win\wininc\struct.inc"/>
+ <CursorPos X="6" Y="4936"/>
+ <TopLine Value="4926"/>
+ <UsageCount Value="8"/>
+ </Unit30>
+ <Unit31>
+ <Filename Value="C:\Develop\lazarus\lcl\include\winapih.inc"/>
+ <CursorPos X="38" Y="4"/>
+ <TopLine Value="1"/>
+ <UsageCount Value="8"/>
+ </Unit31>
+ <Unit32>
+ <Filename Value="C:\Develop\lazarus\lcl\lclintf.pas"/>
+ <UnitName Value="LCLIntf"/>
+ <CursorPos X="1" Y="1"/>
+ <TopLine Value="4"/>
+ <UsageCount Value="8"/>
+ </Unit32>
+ <Unit33>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\classes\classesh.inc"/>
+ <CursorPos X="19" Y="364"/>
+ <TopLine Value="343"/>
+ <UsageCount Value="18"/>
+ </Unit33>
+ <Unit34>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\win32\classes.pp"/>
+ <UnitName Value="Classes"/>
+ <CursorPos X="7" Y="28"/>
+ <TopLine Value="10"/>
+ <UsageCount Value="11"/>
+ </Unit34>
+ <Unit35>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\types.pp"/>
+ <UnitName Value="types"/>
+ <CursorPos X="27" Y="120"/>
+ <TopLine Value="102"/>
+ <UsageCount Value="11"/>
+ </Unit35>
+ <Unit36>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\inc\objpash.inc"/>
+ <CursorPos X="22" Y="153"/>
+ <TopLine Value="135"/>
+ <UsageCount Value="10"/>
+ </Unit36>
+ <Unit37>
+ <Filename Value="D:\lazarus\lcl\include\customcombobox.inc"/>
+ <CursorPos X="51" Y="939"/>
+ <TopLine Value="920"/>
+ <UsageCount Value="9"/>
+ </Unit37>
+ <Unit38>
+ <Filename Value="D:\lazarus\lcl\stdctrls.pp"/>
+ <UnitName Value="StdCtrls"/>
+ <CursorPos X="24" Y="569"/>
+ <TopLine Value="551"/>
+ <UsageCount Value="10"/>
+ </Unit38>
+ <Unit39>
+ <Filename Value="D:\lazarus\lcl\widgetset\wsstdctrls.pp"/>
+ <UnitName Value="WSStdCtrls"/>
+ <CursorPos X="1" Y="407"/>
+ <TopLine Value="5"/>
+ <UsageCount Value="9"/>
+ </Unit39>
+ <Unit40>
+ <Filename Value="D:\lazarus\lcl\include\customlistbox.inc"/>
+ <CursorPos X="1" Y="598"/>
+ <TopLine Value="580"/>
+ <UsageCount Value="10"/>
+ </Unit40>
+ <Unit41>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\inc\wstringh.inc"/>
+ <CursorPos X="11" Y="30"/>
+ <TopLine Value="12"/>
+ <UsageCount Value="10"/>
+ </Unit41>
+ <Unit42>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\classes\stringl.inc"/>
+ <CursorPos X="3" Y="392"/>
+ <TopLine Value="392"/>
+ <UsageCount Value="10"/>
+ </Unit42>
+ <Unit43>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\classes\persist.inc"/>
+ <CursorPos X="82" Y="35"/>
+ <TopLine Value="35"/>
+ <UsageCount Value="10"/>
+ </Unit43>
+ <Unit44>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\inc\systemh.inc"/>
+ <CursorPos X="11" Y="664"/>
+ <TopLine Value="646"/>
+ <UsageCount Value="10"/>
+ </Unit44>
+ <Unit45>
+ <Filename Value="D:\lazarus\lcl\interfaces\win32\win32listsl.inc"/>
+ <CursorPos X="1" Y="206"/>
+ <TopLine Value="188"/>
+ <UsageCount Value="10"/>
+ </Unit45>
+ <Unit46>
+ <Filename Value="D:\lazarus\fpc\2.2.4\source\rtl\objpas\rtlconst.inc"/>
+ <CursorPos X="3" Y="34"/>
+ <TopLine Value="16"/>
+ <UsageCount Value="10"/>
+ </Unit46>
+ </Units>
+ <General>
+ <ActiveEditorIndexAtStart Value="1"/>
+ </General>
+ <JumpHistory Count="2" HistoryIndex="1">
+ <Position1>
+ <Filename Value="u_meal.pas"/>
+ <Caret Line="92" Column="5" TopLine="1"/>
+ </Position1>
+ <Position2>
+ <Filename Value="u_main.pas"/>
+ <Caret Line="2" Column="9" TopLine="1"/>
+ </Position2>
+ </JumpHistory>
+ </ProjectSession>
+ <Debugging>
+ <Exceptions Count="2">
+ <Item1>
+ <Name Value="ECodetoolError"/>
+ </Item1>
+ <Item2>
+ <Name Value="EFOpenError"/>
+ </Item2>
+ </Exceptions>
+ </Debugging>
+</CONFIG>
Added: trunk/gotisso.manifest
===================================================================
--- trunk/gotisso.manifest (rev 0)
+++ trunk/gotisso.manifest 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+ <assemblyIdentity version="1.0.0.0" processorArchitecture="*" name="CompanyName.ProductName.YourApp" type="win32"/>
+ <description>Your application description here.</description>
+ <dependency>
+ <dependentAssembly>
+ <assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*"/>
+ </dependentAssembly>
+ </dependency>
+ <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
+ <security>
+ <requestedPrivileges>
+ <requestedExecutionLevel level="asInvoker" uiAccess="false"/>
+ </requestedPrivileges>
+ </security>
+ </trustInfo>
+</assembly>
\ No newline at end of file
Added: trunk/gotisso.rc
===================================================================
--- trunk/gotisso.rc (rev 0)
+++ trunk/gotisso.rc 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,6 @@
+#define RT_MANIFEST 24
+#define CREATEPROCESS_MANIFEST_RESOURCE_ID 1
+#define ISOLATIONAWARE_MANIFEST_RESOURCE_ID 2
+#define ISOLATIONAWARE_NOSTATICIMPORT_MANIFEST_RESOURCE_ID 3
+
+CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "gotisso.manifest"
Added: trunk/lang/gotisso.po
===================================================================
--- trunk/lang/gotisso.po (rev 0)
+++ trunk/lang/gotisso.po 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,240 @@
+msgid ""
+msgstr "Content-Type: text/plain; charset=UTF-8"
+
+#: TFMINGREDIENTES.BTFECHAR.CAPTION
+msgctxt "TFMINGREDIENTES.BTFECHAR.CAPTION"
+msgid "Fechar"
+msgstr ""
+
+#: TFMINGREDIENTES.BTIMPRIMIR.CAPTION
+msgctxt "TFMINGREDIENTES.BTIMPRIMIR.CAPTION"
+msgid "Imprimir..."
+msgstr ""
+
+#: TFMINGREDIENTES.CAPTION
+msgctxt "TFMINGREDIENTES.CAPTION"
+msgid "Ingredientes"
+msgstr ""
+
+#: TFMINGREDIENTS.BTFECHAR.CAPTION
+msgctxt "TFMINGREDIENTS.BTFECHAR.CAPTION"
+msgid "Fechar"
+msgstr ""
+
+#: TFMINGREDIENTS.BTIMPRIMIR.CAPTION
+msgctxt "TFMINGREDIENTS.BTIMPRIMIR.CAPTION"
+msgid "Imprimir..."
+msgstr ""
+
+#: TFMINGREDIENTS.CAPTION
+msgctxt "TFMINGREDIENTS.CAPTION"
+msgid "Ingredientes"
+msgstr ""
+
+#: TFMMAIN.BTCARLIMPAR.CAPTION
+msgctxt "TFMMAIN.BTCARLIMPAR.CAPTION"
+msgid "Limpar"
+msgstr ""
+
+#: TFMMAIN.BTCARREMOVER.CAPTION
+msgctxt "TFMMAIN.BTCARREMOVER.CAPTION"
+msgid "Remover"
+msgstr ""
+
+#: TFMMAIN.BTIMPRIMIR.CAPTION
+msgctxt "TFMMAIN.BTIMPRIMIR.CAPTION"
+msgid "Imprimir..."
+msgstr ""
+
+#: TFMMAIN.BTINGREDIENTES.CAPTION
+msgid "Lista de Ingredientes..."
+msgstr ""
+
+#: TFMMAIN.BTNOVA.CAPTION
+msgid "Nova..."
+msgstr ""
+
+#: TFMMAIN.BUTTON8.CAPTION
+msgid "Button1"
+msgstr ""
+
+#: TFMMAIN.CAPTION
+msgid "fmMain"
+msgstr ""
+
+#: TFMMAIN.GBCARDAPIO.CAPTION
+msgctxt "TFMMAIN.GBCARDAPIO.CAPTION"
+msgid "Cardápio"
+msgstr ""
+
+#: TFMMAIN.SGCARDAPIO.COLUMNS.TITLE.CAPTION
+msgid "Pratos"
+msgstr ""
+
+#: TFMMEAL.BTADICIONAR.CAPTION
+msgctxt "TFMMEAL.BTADICIONAR.CAPTION"
+msgid "Adicionar"
+msgstr ""
+
+#: TFMMEAL.BTADICIONAREFECHAR.CAPTION
+msgctxt "TFMMEAL.BTADICIONAREFECHAR.CAPTION"
+msgid "Adicionar e Fechar"
+msgstr ""
+
+#: TFMMEAL.BTDOWN.CAPTION
+msgctxt "TFMMEAL.BTDOWN.CAPTION"
+msgid "Abaixo"
+msgstr ""
+
+#: TFMMEAL.BTFECHAR.CAPTION
+msgctxt "TFMMEAL.BTFECHAR.CAPTION"
+msgid "Fechar"
+msgstr ""
+
+#: TFMMEAL.BTLIMPAR.CAPTION
+msgctxt "TFMMEAL.BTLIMPAR.CAPTION"
+msgid "Limpar"
+msgstr ""
+
+#: TFMMEAL.BTPRATO.CAPTION
+msgctxt "TFMMEAL.BTPRATO.CAPTION"
+msgid "Adicionar"
+msgstr ""
+
+#: TFMMEAL.BTREMOVER.CAPTION
+msgctxt "TFMMEAL.BTREMOVER.CAPTION"
+msgid "Remover"
+msgstr ""
+
+#: TFMMEAL.BTUP.CAPTION
+msgctxt "TFMMEAL.BTUP.CAPTION"
+msgid "Acima"
+msgstr ""
+
+#: TFMMEAL.CAPTION
+msgid "fmMeal"
+msgstr ""
+
+#: TFMMEAL.DEDATA.CANCELCAPTION
+msgctxt "TFMMEAL.DEDATA.CANCELCAPTION"
+msgid "Cancelar"
+msgstr ""
+
+#: TFMMEAL.DEDATA.DIALOGTITLE
+msgctxt "TFMMEAL.DEDATA.DIALOGTITLE"
+msgid "Escolha a data"
+msgstr ""
+
+#: TFMMEAL.DEDATA.OKCAPTION
+msgctxt "TFMMEAL.DEDATA.OKCAPTION"
+msgid "OK"
+msgstr ""
+
+#: TFMMEAL.GBREFEICAO.CAPTION
+msgctxt "TFMMEAL.GBREFEICAO.CAPTION"
+msgid "Refeição"
+msgstr ""
+
+#: TFMMEAL.LBLREFEICAO.CAPTION
+msgctxt "TFMMEAL.LBLREFEICAO.CAPTION"
+msgid "Refeição:"
+msgstr ""
+
+#: TFMMEAL.LBPRATO.CAPTION
+msgctxt "TFMMEAL.LBPRATO.CAPTION"
+msgid "Prato:"
+msgstr ""
+
+#: TFMMEAL.LBTIPO.CAPTION
+msgctxt "TFMMEAL.LBTIPO.CAPTION"
+msgid "Tipo:"
+msgstr ""
+
+#: TFMREFEICAO.BTADICIONAR.CAPTION
+msgctxt "TFMREFEICAO.BTADICIONAR.CAPTION"
+msgid "Adicionar"
+msgstr ""
+
+#: TFMREFEICAO.BTADICIONAREFECHAR.CAPTION
+msgctxt "TFMREFEICAO.BTADICIONAREFECHAR.CAPTION"
+msgid "Adicionar e Fechar"
+msgstr ""
+
+#: TFMREFEICAO.BTDOWN.CAPTION
+msgctxt "TFMREFEICAO.BTDOWN.CAPTION"
+msgid "Abaixo"
+msgstr ""
+
+#: TFMREFEICAO.BTFECHAR.CAPTION
+msgctxt "TFMREFEICAO.BTFECHAR.CAPTION"
+msgid "Fechar"
+msgstr ""
+
+#: TFMREFEICAO.BTLIMPAR.CAPTION
+msgctxt "TFMREFEICAO.BTLIMPAR.CAPTION"
+msgid "Limpar"
+msgstr ""
+
+#: TFMREFEICAO.BTPRATO.CAPTION
+msgctxt "TFMREFEICAO.BTPRATO.CAPTION"
+msgid "Adicionar"
+msgstr ""
+
+#: TFMREFEICAO.BTREMOVER.CAPTION
+msgctxt "TFMREFEICAO.BTREMOVER.CAPTION"
+msgid "Remover"
+msgstr ""
+
+#: TFMREFEICAO.BTUP.CAPTION
+msgctxt "TFMREFEICAO.BTUP.CAPTION"
+msgid "Acima"
+msgstr ""
+
+#: TFMREFEICAO.CAPTION
+msgid "fmRefeicao"
+msgstr ""
+
+#: TFMREFEICAO.DEDATA.CANCELCAPTION
+msgctxt "TFMREFEICAO.DEDATA.CANCELCAPTION"
+msgid "Cancelar"
+msgstr ""
+
+#: TFMREFEICAO.DEDATA.DIALOGTITLE
+msgctxt "TFMREFEICAO.DEDATA.DIALOGTITLE"
+msgid "Escolha a data"
+msgstr ""
+
+#: TFMREFEICAO.DEDATA.OKCAPTION
+msgctxt "TFMREFEICAO.DEDATA.OKCAPTION"
+msgid "OK"
+msgstr ""
+
+#: TFMREFEICAO.GBREFEICAO.CAPTION
+msgctxt "TFMREFEICAO.GBREFEICAO.CAPTION"
+msgid "Refeição"
+msgstr ""
+
+#: TFMREFEICAO.LBLREFEICAO.CAPTION
+msgctxt "TFMREFEICAO.LBLREFEICAO.CAPTION"
+msgid "Refeição:"
+msgstr ""
+
+#: TFMREFEICAO.LBPRATO.CAPTION
+msgctxt "TFMREFEICAO.LBPRATO.CAPTION"
+msgid "Prato:"
+msgstr ""
+
+#: TFMREFEICAO.LBTIPO.CAPTION
+msgctxt "TFMREFEICAO.LBTIPO.CAPTION"
+msgid "Tipo:"
+msgstr ""
+
+#: u_consts.serror
+msgid "Error!!!"
+msgstr ""
+
+#: u_consts.stitle
+msgctxt "u_consts.stitle"
+msgid "Gotisso Meal Planner"
+msgstr ""
+
Added: trunk/stringgridprinter.pas
===================================================================
--- trunk/stringgridprinter.pas (rev 0)
+++ trunk/stringgridprinter.pas 2009-11-04 00:33:09 UTC (rev 6)
@@ -0,0 +1,1108 @@
+unit StringGridPrinter;
+{
+This comment block may not be removed or altered.
+No other restrictions are placed on the use of this code.
+TStringGridPrinter unit version 1.2
+Copyright Jonathan Eaton/pr...@on.../August 1999
+
+adapted for FPC/Lazarus by João Marcelo S. Vaz - october/2009
+}
+interface
+
+uses
+ {LCLIntf, LCLType,} Grids, Printers, Graphics, Forms, Classes;
+
+type
+ TPagePosition = (ppNone,ppTopLeft,ppTopMiddle,ppTopRight,ppBottomLeft,
+ ppBottomMiddle,ppBottomRight);
+ TColumnJustification = (cjLeft,cjMiddle,cjRight);
+ THandleExcessText = (hetClip,hetClipAndMark,hetCharWrap,hetWordWrap);
+
+ TColumnFormat = class
+ private
+ //formatting for selected cell (set by SetCellFormatting)
+ CellIsFixed:boolean;
+ CellJustification:TColumnJustification;
+ CellHandleExcessText:THandleExcessText;
+ CellWordDelimChars:string;
+ public
+ //formatting for data cells
+ Justification:TColumnJustification;
+ HandleExcessText:THandleExcessText;
+ WordDelimChars:string;
+ //formatting for cells in fixed rows/columns
+ FixedJustification:TColumnJustification;
+ FixedHandleExcessText:THandleExcessText;
+ FixedWordDelimChars:string;
+ procedure Assign(AColumnFormat:TColumnFormat);
+ constructor Create;
+ procedure SetCellFormatting(AStringGrid:TStringGrid;Col,Row:longInt);
+ end;
+
+ TStringGridPrinter = class
+ private
+ DefaultHandleExcessText,DefaultFixedHandleExcessText:THandleExcessText;
+ DefaultWordDelimChars:string;
+ FStringGrid:TStringGrid;
+ ScreenToPrinterX,ScreenToPrinterY:double;
+ GridCellMarPix:longInt;
+ LeftMarInPix,RightMarInPix,TopMarInPix,BotMarInPix,PrintHeightInPix,
+ PrintWidthInPix,GridTopInPix,GridHeightInPix,TitleTopInPix,
+ TitleLeftInPix,PageNumTopInPix,PageNumLeftInPix:longInt;
+ NonPrintLeftRight,NonPrintTopBottom:longInt;
+ HasHorizontalPages:boolean;
+ VPageCount,HPageCount:longInt;
+ sgPage:TStringGrid;
+ ColumnFormatList:TList;
+ procedure AddGridLines(CellLeft,CellTop:longInt);
+ procedure AdjustColWidths;
+ procedure AdjustRowHeights;
+ function ClipText(StringIn:string;CanvasIn:TCanvas;MaxPix:longInt;
+ Just:TColumnJustification):string;
+ function ColsThisPage(StartingCol:longInt):longInt;
+ function PPIScaleX(PixelsIn:longInt):longInt;
+ function PPIScaleY(PixelsIn:longInt):longInt;
+ procedure PrintPageGrid(CellLeft,CellTop:longInt);
+ function RowsThisPage(StartingRow:longInt):longInt;
+ procedure SetGridCellMarPix;
+ procedure SetMarInPixels;
+ procedure SetScreenToPrinter;
+ procedure SetsgPage(LeftCol,RightCol,TopRow,BottomRow:longInt);
+ procedure SetStringGrid(StringGridIn:TStringGrid);
+ procedure SetTitlePositions;
+ procedure WrapTextToStringList(StringIn:string;CanvasIn:TCanvas;WrappedList:TStringList;
+ MaxPix:longInt;WrapChars:string);
+ public
+ LeftMarInInches:double;
+ RightMarInInches:double;
+ TopMarInInches:double;
+ BotMarInInches:double;
+ PrintGridLines: Boolean;
+ RepeatFixedCols: Boolean;
+ RepeatFixedRows: Boolean;
+ ShadeFixed: Boolean;
+ MarkClipped: Boolean;
+ NoMorePages: Boolean;
+ TitlePosition: TPagePosition;
+ PageNumPosition:TPagePosition;
+ Title:string;
+ PageNumText:string;
+ GridFont:TFont;
+ PageNumFont:TFont;
+ TitleFont:TFont;
+ FixedCellFont:TFont;
+ ShadeFixedColor:TColor;
+ constructor Create;
+ destructor Destroy; override;
+ property AStringGrid:TStringGrid read FStringGrid write SetStringGrid;
+ function GetColumnFormat(Col:longInt):TColumnFormat; overload;
+ function GetColumnFormat(ColName:string):TColumnFormat; overload;
+ procedure Print;
+ procedure SetHandleExcessText(HandleExcessText,FixedHandleExcessText:
+ THandleExcessText;WordDelimChars:string);
+ end;
+
+implementation
+
+uses
+ Dialogs,SysUtils;
+
+//methods of TColumnFormat
+procedure TColumnFormat.Assign(AColumnFormat:TColumnFormat);
+begin
+ Justification := AColumnFormat.Justification;
+ HandleExcessText := AColumnFormat.HandleExcessText;
+ WordDelimChars := AColumnFormat.WordDelimChars;
+ FixedJustification := AColumnFormat.FixedJustification;
+ FixedHandleExcessText := AColumnFormat.FixedHandleExcessText;
+ FixedWordDelimChars := AColumnFormat.FixedWordDelimChars;
+ CellIsFixed := AColumnFormat.CellIsFixed;
+ CellJustification := AColumnFormat.CellJustification;
+ CellHandleExcessText := AColumnFormat.CellHandleExcessText;
+ CellWordDelimChars := AColumnFormat.CellWordDelimChars;
+end;
+
+constructor TColumnFormat.Create;
+begin
+ inherited Create;
+ Justification := cjLeft;
+ HandleExcessText := hetClip;
+ WordDelimChars := ' -/\,;:';
+ FixedJustification := cjLeft;
+ FixedHandleExcessText := hetWordWrap;
+ FixedWordDelimChars := ' -/\,;:';
+ CellIsFixed := false;
+ CellJustification := cjLeft;
+ CellHandleExcessText := hetClip;
+ CellWordDelimChars := '';
+end;
+
+procedure TColumnFormat.SetCellFormatting(AStringGrid:TStringGrid;
+ Col,Row:longInt);
+//set the selected cell members based on whether or not the cell is fixed
+begin
+ if (Col < AStringGrid.FixedCols) or (Row < AStringGrid.FixedRows) then begin
+ CellIsFixed := true;
+ CellJustification := FixedJustification;
+ CellHandleExcessText := FixedHandleExcessText;
+ if (FixedHandleExcessText <> hetWordWrap) then begin
+ CellWordDelimChars := '';
+ end else begin
+ CellWordDelimChars := FixedWordDelimChars;
+ end;
+ end else begin
+ CellIsFixed := false;
+ CellJustification := Justification;
+ CellHandleExcessText := HandleExcessText;
+ if (HandleExcessText <> hetWordWrap) then begin
+ CellWordDelimChars := '';
+ end else begin
+ CellWordDelimChars := WordDelimChars;
+ end;
+ end;
+end;
+
+//methods of TStringGridPrinter
+procedure TStringGridPrinter.AddGridLines(CellLeft,CellTop:longInt);
+//sgPage represents a page full. Draw the grid lines for that page on
+//the printer canvas
+var
+ TotalRowHeight,TotalColWidth,RowAt,RowC,ColAt,ColC:longInt;
+begin
+ Printer.Canvas.Brush.Style := bsClear;
+
+ ColAt := CellLeft;
+ for ColC := 0 to sgPage.ColCount - 1 do begin
+ ColAt := ColAt + PPIScaleX(sgPage.ColWidths[ColC]);
+ end;
+ TotalColWidth := ColAt;
+
+ RowAt := CellTop;
+ for RowC := 0 to sgPage.RowCount - 1 do begin
+ RowAt := RowAt + PPIScaleY(sgPage.RowHeights[RowC]);
+ end;
+ TotalRowHeight := RowAt;
+
+ ColAt := CellLeft;
+ for ColC := 0 to sgPage.ColCount - 1 do begin
+ ColAt := ColAt + PPIScaleX(sgPage.ColWidths[ColC]);
+ Printer.Canvas.MoveTo(ColAt,CellTop);
+ Printer.Canvas.LineTo(ColAt,TotalRowHeight);
+ end;
+
+ RowAt := CellTop;
+ for RowC := 0 to sgPage.RowCount - 1 do
+ begin
+ RowAt := RowAt + PPIScaleY(sgPage.RowHeights[RowC]);
+ Printer.Canvas.MoveTo(CellLeft,RowAt);
+ Printer.Canvas.LineTo(TotalColWidth,RowAt);
+ end;
+
+ Printer.Canvas.Rectangle(CellLeft,CellTop,ColAt,RowAt);
+end;
+
+procedure TStringGridPrinter.AdjustColWidths;
+//This is a little fudging. I don't want a column that has no clipping in the
+//grid to have some clipping in the print-out, so I'm going to find the
+//longest text in the column, and if it's just a little bit wider than the
+//column width, I'm going to make the column width a little bit wider to
+//accomodate it
+var
+ ColC,RowC,MaxTextLength,CellTextLength,ThisDif,MaxDif,AdjDif:longInt;
+ CellText:String;
+begin
+ if (FStringGrid <> nil) then begin
+ AdjDif := PPIScaleX(GridCellMarPix);
+ for ColC := 0 to FStringGrid.ColCount - 1 do begin
+ MaxTextLength := PPIScaleX(FStringGrid.ColWidths[ColC] -
+ (GridCellMarPix * 2));
+ MaxDif := 0;
+ for RowC := 0 to FStringGrid.RowCount - 1 do begin
+ if (ColC < FStringGrid.FixedCols) or (RowC < FStringGrid.FixedRows)
+ then begin
+ Printer.Canvas.Font.Assign(FixedCellFont);
+ end else begin
+ Printer.Canvas.Font.Assign(GridFont);
+ end;
+ CellText := FStringGrid.Cells[ColC,RowC];
+ CellTextLength := Printer.Canvas.TextWidth(CellText);
+ ThisDif := CellTextLength - MaxTextLength;
+ if (ThisDif > MaxDif) then MaxDif := ThisDif;
+ end;
+ if (MaxDif <> 0) and (MaxDif < AdjDif) then begin
+ FStringGrid.ColWidths[ColC] := FStringGrid.ColWidths[ColC] +
+ Round(MaxDif/ScreenToPrinterY) + 1;
+ end;
+ end;
+ end;
+end;
+
+procedure TStringGridPrinter.AdjustRowHeights;
+//Check for columns with word or char wrapping, and adjust the height of the
+//row to accomodate the text
+var
+ CellText:string;
+ WrappedTextList:TStringList;
+ CellTextHeight,MaxPix,ColC,RowC:longInt;
+ ColFormat:TColumnFormat;
+// TextMetrics:TTextMetric;
+begin
+ if (FStringGrid <> nil) then begin
+ WrappedTextList := TStringList.Create;
+ Printer.Canvas.Font.Assign(GridFont);
+// GetTextMetrics(Printer.Canvas.Handle,TextMetrics);
+ try
+ for ColC := 0 to FStringGrid.ColCount - 1 do begin
+ ColFormat := TColumnFormat(ColumnFormatList[ColC]);
+ for RowC := 0 to FStringGrid.RowCount - 1 do begin
+ CellText := FStringGrid.Cells[ColC,RowC];
+ if (CellText <> '') then begin
+ ColFormat.SetCellFormatting(FStringGrid,ColC,RowC);
+ if (ColFormat.CellIsFixed) then begin
+ Printer.Canvas.Font.Assign(FixedCellFont);
+ end else begin
+ Printer.Canvas.Font.Assign(GridFont);
+ end;
+ if (ColFormat.CellHandleExcessText in
+ [hetCharWrap,hetWordWrap]) then begin
+ MaxPix := PPIScaleX(FStringGrid.ColWidths[ColC] -
+ (GridCellMarPix * 2));
+ if (Printer.Canvas.TextWidth(CellText) > MaxPix) then begin
+ WrapTextToStringList(CellText,Printer.Canvas,
+ WrappedTextList,MaxPix,ColFormat.CellWordDelimChars);
+ if (WrappedTextList.Count > 1) then begin
+ //must be sure that the row height will be big
+ //enough, so first I'm going to calculate it as if
+ //for the printer canvas, then convert it back to
+ //the string grid. Funky - but it works
+ CellTextHeight :=
+ (Printer.Canvas.Font.FontData.Height * WrappedTextList.Count) +
+ PPIScaleY(GridCellMarPix * 2);
+ {(TextMetrics.tmHeight * WrappedTextList.Count) +
+ PPIScaleY(GridCellMarPix * 2); }
+ CellTextHeight :=
+ Round(CellTextHeight/ScreenToPrinterY) + 1;
+ if CellTextHeight > FStringGrid.RowHeights[RowC] then
+ begin
+ FStringGrid.RowHeights[RowC] := CellTextHeight;
+ end;
+ end;
+ end;
+ end; //excess text should be wrapped
+ end; //cell has text
+ end; //check every cell in column for wrapping
+ end; //check column for wrapping
+ finally
+ WrappedTextList.Free;
+ end;
+ end;
+end;
+
+function TStringGridPrinter.ClipText(StringIn:string;CanvasIn:TCanvas;
+ MaxPix:longInt;Just:TColumnJustification):string;
+//I tried to let windows do the clipping, but it kept allowing text to cross my
+//grid lines, so finally I decided to do it myself.
+var
+ AveCharWidth,CharStartAt,CharsInString:longInt;
+
+ procedure GetNewString;
+ begin
+ case Just of
+ cjLeft:begin
+ Result := copy(StringIn,1,CharsInString);
+ end;
+ cjMiddle:begin
+ CharStartAt := (Length(StringIn) - CharsInString) div 2;
+ if (CharStartAt < 1) then CharStartAt := 1;
+ Result := copy(StringIn,CharStartAt,CharsInString);
+ end;
+ cjRight:begin
+ Result := copy(StringIn,(Length(StringIn) - CharsInString)+1,
+ CharsInString);
+ end;
+ end;
+ end;
+
+begin
+ Result := StringIn;
+ if (Result) = '' then Exit;
+ AveCharWidth := CanvasIn.TextWidth(Result) div Length(Result);
+ CharsInString := (MaxPix div AveCharWidth);
+ GetNewString;
+
+ while (CanvasIn.TextWidth(Result) < MaxPix) and (Result <> StringIn) do begin
+ inc(CharsInString);
+ GetNewString;
+ end;
+
+ while (CanvasIn.TextWidth(Result) > MaxPix) and (Result <> '') do begin
+ dec(CharsInString);
+ GetNewString;
+ end;
+
+ if (Result = '') then Result := StringIn[1];
+end;
+
+function TStringGridPrinter.ColsThisPage(StartingCol:longInt):longInt;
+//calculate the number of columns that can fit on this page.
+var
+ ColC,TotalColWidth:longInt;
+begin
+ Result := 0;
+ if (FStringGrid <> nil) then begin
+ TotalColWidth := 0;
+
+ if (RepeatFixedCols) and (StartingCol > 0) then begin
+ for ColC := 0 to FStringGrid.FixedCols - 1 do begin
+ TotalColWidth := TotalColWidth +
+ PPIScaleX(FStringGrid.ColWidths[ColC]);
+ end;
+ end;
+
+ for ColC := StartingCol to FStringGrid.ColCount - 1 do
+ begin
+ TotalColWidth := TotalColWidth + PPIScaleX(FStringGrid.ColWidths[ColC]);
+ if (TotalColWidth <= PrintWidthInPix) then inc(Result) else Exit;
+ end;
+ end;
+end;
+
+constructor TStringGridPrinter.Create;
+begin
+ inherited Create;
+ ColumnFormatList := TList.Create;
+ DefaultHandleExcessText := hetClip;
+ DefaultFixedHandleExcessText := hetWordWrap;
+ DefaultWordDelimChars := ' -/\,;:';
+ FStringGrid := nil;
+ sgPage := nil;
+ GridFont := TFont.Create;
+ TitleFont := TFont.Create;
+ FixedCellFont := TFont.Create;
+ PageNumFont := TFont.Create;
+ ShadeFixedColor := $00f0f0f0;
+ ScreenToPrinterX := 1;
+ ScreenToPrinterY := 1;
+ LeftMarInInches := 1;
+ RightMarInInches := 1;
+ TopMarInInches := 1;
+ BotMarInInches := 1;
+ PrintGridLines := true;
+ TitlePosition := ppTopMiddle;
+ PageNumPosition := ppTopRight;
+ PageNumText := 'page ';
+end;
+
+destructor TStringGridPrinter.Destroy;
+var
+ ColC:longInt;
+begin
+ if (sgPage <> nil) then sgPage.Free;
+ GridFont.Free;
+ TitleFont.Free;
+ FixedCellFont.Free;
+ PageNumFont.Free;
+ for ColC := 0 to ColumnFormatList.Count - 1 do
+ begin
+ TColumnFormat(ColumnFormatList[ColC]).Free;
+ end;
+ ColumnFormatList.Free;
+ if (FStringGrid <> nil) then FStringGrid.Free;
+ inherited Destroy;
+end;
+
+function TStringGridPrinter.GetColumnFormat(Col:longInt):TColumnFormat;
+begin
+ Result := nil;
+ if (FStringGrid = nil) then Exit;
+ if (Col < 0) then Exit;
+ if (Col >= ColumnFormatList.Count) then Exit;
+ Result := TColumnFormat(ColumnFormatList[Col]);
+end;
+
+function TStringGridPrinter.GetColumnFormat(ColName:string):TColumnFormat;
+var
+ UColName:string;
+ ColC:longInt;
+begin
+ Result := nil;
+ if (FStringGrid = nil) then Exit;
+ UColName := UpperCase(ColName);
+ for ColC := 0 to ColumnFormatList.Count - 1 do begin
+ if (UColName = UpperCase(FStringGrid.Cells[ColC,0])) then begin
+ Result := TColumnFormat(ColumnFormatList[ColC]);
+ end;
+ end;
+end;
+
+function TStringGridPrinter.PPIScaleX(PixelsIn:longInt):longInt;
+begin
+ Result := Round(ScreenToPrinterX * PixelsIn);
+end;
+
+function TStringGridPrinter.PPIScaleY(PixelsIn:longInt):longInt;
+begin
+ Result := Round(ScreenToPrinterY * PixelsIn);
+end;
+
+procedure TStringGridPrinter.Print;
+var
+ ColS,RowS,StartingRow,StartingCol:longInt;
+ VPagesDone,HPagesDone,FirstPage:boolean;
+begin
+ if (FStringGrid <> nil) then begin
+ StartingCol := 0;
+ try
+ Printer.BeginDoc;
+ SetScreenToPrinter;
+ SetMarInPixels;
+ SetTitlePositions;
+ AdjustColWidths;
+ AdjustRowHeights;
+
+ HPagesDone := false;
+ FirstPage := true;
+
+ HPageCount := 0;
+ repeat
+ inc(HPageCount);
+ ColS := ColsThisPage(StartingCol);
+ if (StartingCol = 0) and (ColS < FStringGrid.ColCount) then begin
+ HasHorizontalPages := true;
+ end;
+ if (ColS > 0) then begin
+ VPagesDone := false;
+ StartingRow := 0;
+ VPageCount := 0;
+ repeat
+ inc(VPageCount);
+ if FirstPage then FirstPage := false else Printer.NewPage;
+ RowS := RowsThisPage(StartingRow);
+ if (RowS > 0) then begin
+ if (sgPage <> nil) then begin
+ sgPage.Free;
+ sgPage := nil;
+ end;
+ SetsgPage(StartingCol,(StartingCol+ColS)-1,
+ StartingRow,(StartingRow+RowS)-1);
+ PrintPageGrid(LeftMarInPix,GridTopInPix);
+ if PrintGridLines then begin
+ AddGridLines(LeftMarInPix,GridTopInPix);
+ end;
+ StartingRow := StartingRow + RowS;
+ if StartingRow >= (FStringGrid.RowCount - 1) then begin
+ VPagesDone := true;
+ end;
+ end else begin
+ VPagesDone := true;
+ end;
+ until (VPagesDone) or (NoMorePages);
+
+ StartingCol := StartingCol + ColS;
+ if StartingCol >= (FStringGrid.ColCount - 1) then begin
+ HPagesDone := true;
+ end;
+ end else begin
+ HPagesDone := true;
+ end;
+ until (HPagesDone) or (NoMorePages);
+ Printer.EndDoc;
+ finally
+ end;
+ end;
+end;
+
+procedure TStringGridPrinter.PrintPageGrid(CellLeft,CellTop:longInt);
+var
+ ColC,RowC,CellTextLength,MaxTextLength,LeftPos,TopPos,LineC,
+ CellRight:longInt;
+ TextOutRect,ClipMarkRect:TRect;
+ CellText,AllPageNumText:string;
+ WrappedTextList:TStringList;
+ ColFormat:TColumnFormat;
+// TextMetrics:TTextMetric;
+ Clipped:boolean;
+begin
+ if (sgPage <> nil) then begin
+ Printer.Canvas.Brush.Style := bsClear;
+ if (Title <> '') and (TitlePosition <> ppNone) then begin
+ Printer.Canvas.Font.Assign(TitleFont);
+ Printer.Canvas.TextOut(TitleLeftInPix,TitleTopInPix,Title);
+ end;
+
+ if (PageNumPosition <> ppNone) then begin
+ if HasHorizontalPages then begin
+ AllPageNumText := PageNumText+' '+IntToStr(VPageCount)+'/'+
+ IntToStr(HPageCount);
+ end else begin
+ AllPageNumText := PageNumText+' '+IntToStr(VPageCount);
+ end;
+
+ Printer.Canvas.Font.Assign(PageNumFont);
+ Printer.Canvas.TextOut(PageNumLeftInPix,PageNumTopInPix,
+ AllPageNumText);
+ end;
+
+// GetTextMetrics(Printer.Canvas.Handle,TextMetrics);
+
+ WrappedTextList := TStringList.Create;
+
+ for ColC := 0 to sgPage.ColCount - 1 do begin
+ ColFormat := TColumnFormat(sgPage.Objects[ColC,0]);
+ CellRight := CellLeft + PPIScaleX(sgPage.ColWidths[ColC]);
+
+ TextOutRect.Left := CellLeft;
+ TextOutRect.Top := CellTop;
+ TextOutRect.Right := CellRight;
+
+ MaxTextLength := PPIScaleX(sgPage.ColWidths[ColC] -
+ (GridCellMarPix * 2));
+
+ for RowC := 0 to sgPage.RowCount - 1 do begin
+ ColFormat.SetCellFormatting(sgPage,ColC,RowC);
+
+ LeftPos := TextOutRect.Left + PPIScaleX(GridCellMarPix);
+ TopPos := TextOutRect.Top + PPIScaleY(GridCellMarPix);
+
+ TextOutRect.Bottom := TextOutRect.Top +
+ PPIScaleY(sgPage.RowHeights[RowC]);
+
+ if (ColC < sgPage.FixedCols) or (RowC < sgPage.FixedRows) then begin
+ Printer.Canvas.Font.Assign(FixedCellFont);
+ if ShadeFixed then begin
+ Printer.Canvas.Brush.Color := ShadeFixedColor;
+ Printer.Canvas.Brush.Style := bsSolid;
+ Printer.Canvas.FillRect(TextOutRect);
+ Printer.Canvas.Brush.Color := clWhite;
+ Printer.Canvas.Brush.Style := bsClear;
+ end;
+ end else begin
+ Printer.Canvas.Font.Assign(GridFont);
+ end;
+
+ CellText := Trim(sgPage.Cells[ColC,RowC]);
+ CellTextLength := Printer.Canvas.TextWidth(CellText);
+
+ case ColFormat.CellHandleExcessText of
+ hetClip:begin
+ if (CellTextLength > MaxTextLength) then begin
+ CellText := Trim(ClipText(CellText,Printer.Canvas,
+ MaxTextLength,ColFormat.CellJustification));
+ CellTextLength := Printer.Canvas.TextWidth(CellText);
+ end;
+
+ case ColFormat.Justification of
+ cjMiddle:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ ((MaxTextLength - CellTextLength) div 2);
+ cjRight:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ (MaxTextLength - CellTextLength);
+ end;
+
+ Printer.Canvas.TextOut(LeftPos,TopPos,CellText);
+ end;
+ hetClipAndMark:begin
+ Clipped := false;
+ if (CellTextLength > MaxTextLength) then begin
+ Clipped := true;
+ CellText := Trim(ClipText(CellText,Printer.Canvas,
+ MaxTextLength,ColFormat.CellJustification));
+ CellTextLength := Printer.Canvas.TextWidth(CellText);
+ end;
+
+ case ColFormat.Justification of
+ cjMiddle:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ ((MaxTextLength - CellTextLength) div 2);
+ cjRight:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ (MaxTextLength - CellTextLength);
+ end;
+
+ if Clipped then begin
+ Printer.Canvas.Brush.Color := clSilver;
+ Printer.Canvas.Brush.Style := bsSolid;
+ ClipMarkRect.Top := TextOutRect.Top + PPIScaleX(GridCellMarPix);
+ ClipMarkRect.Bottom := TextOutRect.Bottom - PPIScaleX(GridCellMarPix);
+ case ColFormat.CellJustification of
+ cjLeft:begin
+ ClipMarkRect.Left := LeftPos + CellTextLength;
+ ClipMarkRect.Right := TextOutRect.Right;
+ Printer.Canvas.FillRect(ClipMarkRect);
+ end;
+ cjMiddle:begin
+ ClipMarkRect.Left := TextOutRect.Left;
+ ClipMarkRect.Right := LeftPos;
+ Printer.Canvas.FillRect(ClipMarkRect);
+ ClipMarkRect.Left := LeftPos + CellTextLength;
+ ClipMarkRect.Right := TextOutRect.Right;
+ Printer.Canvas.FillRect(ClipMarkRect);
+ end;
+ cjRight:begin
+ ClipMarkRect.Left := TextOutRect.Left;
+ ClipMarkRect.Right := LeftPos;
+ Printer.Canvas.FillRect(ClipMarkRect);
+ end;
+ end;
+ Printer.Canvas.Brush.Color := clWhite;
+ Printer.Canvas.Brush.Style := bsClear;
+ end;
+
+ Printer.Canvas.TextOut(LeftPos,TopPos,CellText);
+ end;
+ hetCharWrap,hetWordWrap:begin
+ if (CellTextLength > MaxTextLength) then begin
+ WrapTextToStringList(CellText,Printer.Canvas,
+ WrappedTextList,MaxTextLength,
+ ColFormat.CellWordDelimChars);
+ for LineC := 0 to WrappedTextList.Count - 1 do begin
+ CellText := WrappedTextList[LineC];
+ CellTextLength := Printer.Canvas.TextWidth(CellText);
+ case ColFormat.Justification of
+ cjMiddle:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ ((MaxTextLength - CellTextLength) div 2);
+ cjRight:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ (MaxTextLength - CellTextLength);
+ end;
+
+ Printer.Canvas.TextOut(LeftPos,TopPos,CellText);
+
+ {TopPos := TopPos + TextMetrics.tmHeight;}
+ TopPos := TopPos + Printer.Canvas.Font.FontData.Height
+ end;
+ end else begin
+ case ColFormat.Justification of
+ cjMiddle:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ ((MaxTextLength - CellTextLength) div 2);
+ cjRight:LeftPos := TextOutRect.Left +
+ PPIScaleX(GridCellMarPix) +
+ (MaxTextLength - CellTextLength);
+ end;
+
+ Printer.Canvas.TextOut(LeftPos,TopPos,CellText);
+ end;
+ end;
+ end;
+ TextOutRect.Top := TextOutRect.Bottom;
+ end;
+ CellLeft := CellRight;
+ end;
+ WrappedTextList.Free;
+ end;
+end;
+
+function TStringGridPrinter.RowsThisPage(StartingRow:longInt):longInt;
+var
+ RowC,TotalRowHeight:longInt;
+begin
+ Result := 0;
+ if (FStringGrid <> nil) then begin
+ TotalRowHeight := 0;
+ if (RepeatFixedRows) and (StartingRow > 0) then begin
+ for RowC := 0 to FStringGrid.FixedRows - 1 do begin
+ TotalRowHeight := TotalRowHeight +
+ PPIScaleY(FStringGrid.RowHeights[RowC]);
+ end;
+ end;
+
+ for RowC := StartingRow to FStringGrid.RowCount - 1 do
+ begin
+ TotalRowHeight := TotalRowHeight + PPIScaleY(FStringGrid.RowHeights[RowC]);
+ if (TotalRowHeight <= GridHeightInPix) then inc(Result) else Exit;
+ end;
+ end;
+end;
+
+procedure TStringGridPrinter.SetGridCellMarPix;
+begin
+ if (FStringGrid <> nil) then begin
+ FStringGrid.Canvas.Font.Assign(GridFont);
+ GridCellMarPix := FStringGrid.Canvas.TextWidth('x') div 2;
+ if (GridCellMarPix < 1) then GridCellMarPix := 1;
+ end;
+end;
+
+procedure TStringGridPrinter.SetHandleExcessText(HandleExcessText,
+ FixedHandleExcessText:THandleExcessText;WordDelimChars:string);
+var
+ ColC:longInt;
+ ColumnFormat:TColumnFormat;
+begin
+ DefaultHandleExcessText := HandleExcessText;
+ DefaultFixedHandleExcessText := FixedHandleExcessText;
+ DefaultWordDelimChars := WordDelimChars;
+ for ColC := 0 to ColumnFormatList.Count - 1 do begin
+ ColumnFormat := TColumnFormat(ColumnFormatList[ColC]);
+ ColumnFormat.HandleExcessText := HandleExcessText;
+ ColumnFormat.FixedHandleExcessText := FixedHandleExcessText;
+ ColumnFormat.WordDelimChars := WordDelimChars;
+ end;
+end;
+
+procedure TStringGridPrinter.SetMarInPixels;
+begin
+
+{
+
+ PHYSICALWIDTH := Printer.PaperSize.PaperRect.PhysicalRect.Right-PhysicalRect.Left; // GetDeviceCaps(Handle, PHYSICALWIDTH);
+ PHYSICALHEIGHT := Printer.PaperSize.PaperRect.PhysicalRect.Bottom-PhysicalRect.Top; // GetDeviceCaps(Handle, PHYSICALHEIGHT);
+ PHYSICALOFFSETX := Printer.PaperSize.PaperRect.WorkRect.Left; //GetDeviceCaps(Handle, PHYSICALOFFSETX);
+ PHYSICALOFFSETX := Printer.PaperSize.PaperRect.WorkRect.Top; //GetDeviceCaps(Handle, PHYSICALOFFSETX);
+ PageWidth := Printer.PaperSize.PaperRect.WorkRect.Right-WorkRect.Left; // this is the same as PageWidth
+ PageHeight := Printer.PaperSize.PaperRect.WorkRect.Bottom-WorkRect.Top; // this is the same as PageHeight
+
+}
+
+
+ NonPrintLeftRight := Printer.PaperSize.PaperRect.WorkRect.Left;;
+ NonPrintTopBottom := Printer.PaperSize.PaperRect.WorkRect.Top ;
+
+ LeftMarInPix := Round(Printer.XDPI * LeftMarInInches) - NonPrintLeftRight;
+ RightMarInPix := Round(Printer.XDPI * RightMarInInches) - NonPrintLeftRight;
+ TopMarInPix := Round(Printer.YDPI * TopMarInInches) - NonPrintTopBottom;
+ BotMarInPix := Round(Printer.YDPI * BotMarInInches) - NonPrintTopBottom;
+ PrintWidthInPix := Printer.PageWidth - (LeftMarInPix + RightMarInPix);
+ PrintHeightInPix := Printer.PageHeight - (TopMarInPix + BotMarInPix);
+
+ if (LeftMarInPix < 0) then LeftMarInPix := 0;
+ if (RightMarInPix < 0) then RightMarInPix := 0;
+ if (TopMarInPix < 0) then TopMarInPix := 0;
+ if (BotMarInPix < 0) then BotMarInPix := 0;
+
+ GridTopInPix := TopMarInPix;
+ GridHeightInPix := PrintHeightInPix;
+end;
+
+procedure TStringGridPrinter.SetScreenToPrinter;
+begin
+ ScreenToPrinterX := 1;
+ ScreenToPrinterY := 1;
+
+ if Printer.XDPI = 0 then Exit;
+ if Printer.YDPI = 0 then Exit;
+ if ScreenInfo.PixelsPerInchX = 0 then Exit;
+ if ScreenInfo.PixelsPerInchY = 0 then Exit;
+
+ ScreenToPrinterX := Printer.XDPI/ScreenInfo.PixelsPerInchX;
+ ScreenToPrinterY := Printer.YDPI/ScreenInfo.PixelsPerInchY;
+end;
+
+procedure TStringGridPrinter.SetsgPage(LeftCol,RightCol,TopRow,
+ BottomRow:longInt);
+//Create a StringGrid which represents what will fit on one page based on
+//margins, column widths, paper size, etc... Also, if fixed rows, cols are to
+//be repeated on each new page, these need to be added to the sgPage StringGrid.
+var
+ ColS,RowS,ColC,RowC,FixedColShift,FixedRowShift:longInt;
+begin
+ if (FStringGrid <> nil) then begin
+ ColS := (RightCol - LeftCol) + 1;
+ RowS := (BottomRow - TopRow) + 1;
+ FixedColShift := 0;
+ FixedRowShift := 0;
+
+ if (sgPage = nil) then begin
+ sgPage := TStringGrid.Create(FStringGrid.Parent);
+ sgPage.Font.Assign(FStringGrid.Font);
+ end;
+
+ sgPage.FixedCols := 0;
+ sgPage.FixedRows := 0;
+ if (LeftCol = 0) or (RepeatFixedCols) then begin
+ sgPage.FixedCols := FStringGrid.FixedCols;
+ end;
+ if (TopRow = 0) or (RepeatFixedRows) then begin
+ sgPage.FixedRows := FStringGrid.FixedRows;
+ end;
+
+ if ((RepeatFixedCols) and (FStringGrid.FixedCols > 0) and (LeftCol > 0))
+ then begin
+ FixedColShift := FStringGrid.FixedCols;
+ end;
+
+ if ((RepeatFixedRows) and (FStringGrid.FixedRows > 0) and (TopRow > 0))
+ then begin
+ FixedRowShift := FStringGrid.FixedRows;
+ end;
+
+ if (FixedColShift > 0) then begin
+ sgPage.ColCount := Cols + FStringGrid.FixedCols;
+ FixedColShift := FStringGrid.FixedCols;
+ for ColC := 0 to FixedColShift - 1 do begin
+ sgPage.ColWidths[ColC] := FStringGrid.ColWidths[ColC];
+ sgPage.Objects[ColC,0] := GetColumnFormat(ColC);
+ for RowC := TopRow to BottomRow do begin
+ sgPage.Cells[ColC,(RowC-TopRow)+FixedRowShift]
+ := FStringGrid.Cells[ColC,RowC];
+ end;
+ end;
+ end else begin
+ sgPage.ColCount := ColS;
+ end;
+
+ if (FixedRowShift > 0) then begin
+ sgPage.RowCount := RowS + FStringGrid.FixedRows;
+ FixedRowShift := FStringGrid.FixedRows;
+ for RowC := 0 to FStringGrid.FixedRows - 1 do begin
+ sgPage.RowHeights[RowC] := FStringGrid.RowHeights[RowC];
+ for ColC := LeftCol to RightCol do begin
+ sgPage.Cells[(ColC-LeftCol)+FixedColShift,RowC]
+ := FStringGrid.Cells[ColC,RowC];
+ end;
+ end;
+ end else begin
+ sgPage.RowCount := RowS;
+ end;
+
+ if ((FixedColShift > 0) and (FixedRowShift > 0)) then
+ begin
+ for ColC := 0 to FixedColShift - 1 do begin
+ for RowC := 0 to FixedRowShift - 1 do begin
+ sgPage.Cells[ColC,RowC] := FStringGrid.Cells[ColC,RowC];
+ end;
+ end;
+ end;
+
+ for ColC := LeftCol to RightCol do begin
+ sgPage.ColWidths[(ColC-LeftCol)+FixedColShift] :=
+ FStringGrid.ColWidths[ColC];
+ end;
+
+ for RowC := TopRow to BottomRow do begin
+ sgPage.RowHeights[(RowC-TopRow)+FixedRowShift] :=
+ FStringGrid.RowHeights[RowC];
+ end;
+
+ for ColC := LeftCol to RightCol do begin
+ sgPage.Objects[(ColC-LeftCol)+FixedColShift,0] := GetColumnFormat(ColC);
+ for RowC := TopRow to BottomRow do begin
+ sgPage.Cells[(ColC-LeftCol)+FixedColShift,
+ (RowC-TopRow)+FixedRowShift] := FStringGrid.Cells[ColC,RowC...
[truncated message content] |
|
From: <jm...@us...> - 2009-11-04 00:05:14
|
Revision: 5
http://gotisso.svn.sourceforge.net/gotisso/?rev=5&view=rev
Author: jmvaz
Date: 2009-11-04 00:05:06 +0000 (Wed, 04 Nov 2009)
Log Message:
-----------
creating directory structure
Added Paths:
-----------
documentation/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-11-04 00:04:14
|
Revision: 4
http://gotisso.svn.sourceforge.net/gotisso/?rev=4&view=rev
Author: jmvaz
Date: 2009-11-04 00:04:00 +0000 (Wed, 04 Nov 2009)
Log Message:
-----------
creating directory structure
Added Paths:
-----------
website/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-11-04 00:01:40
|
Revision: 3
http://gotisso.svn.sourceforge.net/gotisso/?rev=3&view=rev
Author: jmvaz
Date: 2009-11-04 00:01:34 +0000 (Wed, 04 Nov 2009)
Log Message:
-----------
creating directory structure
Added Paths:
-----------
branches/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-11-04 00:00:39
|
Revision: 2
http://gotisso.svn.sourceforge.net/gotisso/?rev=2&view=rev
Author: jmvaz
Date: 2009-11-04 00:00:32 +0000 (Wed, 04 Nov 2009)
Log Message:
-----------
creating directory structure
Added Paths:
-----------
tags/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jm...@us...> - 2009-11-03 23:59:14
|
Revision: 1
http://gotisso.svn.sourceforge.net/gotisso/?rev=1&view=rev
Author: jmvaz
Date: 2009-11-03 23:59:03 +0000 (Tue, 03 Nov 2009)
Log Message:
-----------
creating directory structure
Added Paths:
-----------
trunk/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|