Add support for i18n of price source strings. #102156

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@7767 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
David Hampton 2003-01-04 06:32:48 +00:00
parent f4a1432582
commit b3f1274e0a
3 changed files with 48 additions and 15 deletions

View File

@ -1,22 +1,44 @@
2003-01-03 David Hampton <hampton@employees.org>
* src/engine/gnc-pricedb.h:
* src/gnome/dialog-price-edit-db.c: Add support for i18n of price
source strings. Needs to be done at display time because the
strings are embedded into the data file. #102156
* src/import-export/qif-import/druid-qif-import.c:
* src/import-export/qif-import/qif.glade: Add a smart function for
going "back" from the "load a file" page. If there are any files
loaded it returns to the "loaded files" page instead of the
initial druid page. #101818
* src/backend/file/gnc-backend-file.c
(gnc_file_be_load_from_file): Don't free the lockfile name any
time there is an error. Wait for the session to be destroyed so
the lockfile will be cleaned up properly. #101004
* src/app-file/gnc-file.c (gnc_file_query_save): Grab the current
session each time around the while loop so as not to have a
dangling pointer. #101004
2003-01-03 Derek Atkins <derek@ihtfp.com>
* src/business/business-gnome/glade/invoice.glade: fix a string
to make the meaning more clear (per user request)
2003-01-03 Matthew Vanecek <mevanecek@yahoo.com>
* src/backend/postgres/Postgresbackend.c: Fixed some compiler
warning messages about MODE_NONE and a some GUIDs used as
string pointers in informational messages.
* src/backend/postgres/Postgresbackend.c: Fixed some compiler
warning messages about MODE_NONE and a some GUIDs used as
string pointers in informational messages.
* src/backend/postgres/test/test-db.c: Commented out the
"short module" declaration. It was not used and was causing a
compiler warning.
* src/backend/postgres/test/test-db.c: Commented out the
"short module" declaration. It was not used and was causing a
compiler warning.
* src/backend/postgres/upgrade.c: Changed the "ALTER TABLE table
ADD COLUMN..." statements to conform to the current Postgres
implementation (and SQL 92) standard by putting the DEFAULT
modifier in a separate ALTER statement. This was reported by
Christopher B. Browne.
* src/backend/postgres/upgrade.c: Changed the "ALTER TABLE table
ADD COLUMN..." statements to conform to the current Postgres
implementation (and SQL 92) standard by putting the DEFAULT
modifier in a separate ALTER statement. This was reported by
Christopher B. Browne.
2003-01-02 David Hampton <hampton@employees.org>
@ -952,7 +974,7 @@
* src/register/ledger-core/split-register-model.c:
put the "proper" exchange rate in the RATE_CELL
fix the print_info
v fix the print_info
use ALLOW_SHADOW so the rate-cell gets copied into the cursor
* src/register/ledger-core/split-register.c:

View File

@ -74,7 +74,12 @@
"user:misc", "user:foo", etc. If the quote came from a user,
as a matter of policy, you *must* prefix the string you give
with "user:". For now, the only other reserved values are
"Finance::Quote" and "old-file-import".
"Finance::Quote" and "old-file-import". Any string used must
be added to the source_list array in dialog-price-edit-db.c so
that it can be properly translated. (There are unfortunately
many strings in users databased, so this string must be
translated on output instead of always being used intranslated
form.)
type: the type of quote - types possible right now are bid, ask,
last, nav, and unknown.

View File

@ -70,7 +70,13 @@ typedef struct
GList * prices; /* All prices */
} PricesDialog;
const char *price_sources[] = {
N_("old-file-import"),
N_("user:price-editor"),
N_("user:stock-split"),
N_("user:xfer-dialog")
};
static gint last_width = 0;
static gint last_height = 0;
@ -213,7 +219,7 @@ gnc_prices_load_prices (PricesDialog *pdb_dialog)
text[0] = gnc_commodity_get_printname (gnc_price_get_commodity (price));
text[1] = gnc_commodity_get_printname (gnc_price_get_currency (price));
text[2] = gnc_print_date (gnc_price_get_time (price));
text[3] = gnc_price_get_source (price);
text[3] = gettext(gnc_price_get_source (price));
text[4] = gnc_price_get_type (price);
text[5] = xaccPrintAmount (gnc_price_get_value (price), print_info);