Page 2 of 3
Re: issue-#80 localizable menus
Posted: Mon Nov 16, 2015 7:46 am
by DGDanforth
I would use
Undo Deletion
Redo Deletion
-Doug
Re: issue-#80 localizable menus
Posted: Wed Nov 18, 2015 4:22 pm
by Josef Templ
I have added subsystem Dev as proposed by CPC 1.7 rc6 with the following
small modifications:
1. key 'Clear Log' was not unique, so I changed it in the menu to 'ClearLog'.
2. The keys starting with 'Ctls' don't belong to Dev but to the CPC package Ctls, so they have been removed.
For the subsystem 'System' there are multiple ambiguous keys in Strings:
Code: Select all
CheckKeys subsys=System
key not unique: Close
key not unique: Examples
key not unique: Help
key not unique: Redo
key not unique: Undo
CheckKeys subsys=Host
key not unique: HostBitmaps.ExportBitmap
We should find a way to get rid of them.
For #Host:HostBitmaps.ExportBitmap it is a simple delete.
For the changes see
http://redmine.blackboxframework.org/pr ... 73a1e4c1b7.
- Josef
Re: issue-#80 localizable menus
Posted: Thu Nov 19, 2015 11:27 am
by Josef Templ
I have now also added menu Text as proposed by CPC 1.7.
The String resources for the text dialogs, as opposed to the menus,
are not yet included because those belong to another issue (localizable forms).
Also the color blue for the CPC 1.7 changes has been reset to Default Color.
For the changes see
http://redmine.blackboxframework.org/pr ... 663e3a01af.
- Josef
Re: issue-#80 localizable menus
Posted: Mon Nov 23, 2015 8:49 am
by Josef Templ
Form and Sql menus added as proposed in CPC 1.7 rc6 with the following small modification:
Strings resources for form/sql dialogs are not yet included because they belong to a different issue.
Now all menus are localizable except for 'Obx'.
How should we proceed with that one? Can we ignore it?
In addition I have resolved the ambiguity of several newly added keys in System/Rsrc/Strings
by appending _ to the ambiguous keys that have been introduced for this issue.
I have also added a simple debug feature in module Dialog.
Missing and duplicate keys in Strings resources can be logged by switching a logXXX debug flag on.
This helps in finding inconsistencies with Strings resources. Since it is a very simple
feature that we will also need for making dialog forms localizable I propose to leave it in the source code
at least for now.
By using the mentioned debug feature I have uncovered a bug in DevInspector.GetTypeName and MapLabel).
It creates illegal subsystem names ("Control."). This has currently no effect but it is definitely a bug and I have fixed it.
The debug feature confirmed that there are missing keys in System/Rsrc/Strings as observed before by Helmut.
#System:Inserting and Deleting have therefore been added as in CPC 1.7 rc6.
So far, I have not found any other missing 'simple' keys.
For the changes see
http://redmine.blackboxframework.org/pr ... c0ad1796da.
- Josef
Re: issue-#80 localizable menus
Posted: Mon Nov 23, 2015 12:30 pm
by Robert
Josef Templ wrote:Now all menus are localizable except for 'Obx'.
How should we proceed with that one? Can we ignore it?
I think we can leave it.
But since English is my native language my opinion may be considered biased!
Robert
Re: issue-#80 localizable menus
Posted: Mon Nov 23, 2015 3:45 pm
by Zinn
Hi Josef,
in DevInspector you fix a bug by adding a line behind Kernel.SplitName:
Kernel.SplitName(control, subs, cntr);
IF subs[LEN(subs$) - 1] = "." THEN (* no subsystem *) subs := "System"; cntr := control$ END;
Is it not better to insert this IF line into the procedure Kernel.SplitName itself?
Otherwise we have to do the same bug fix in 10 other modules too.
- Helmut
Re: issue-#80 localizable menus
Posted: Mon Nov 23, 2015 3:48 pm
by Zinn
About the Obx question: I'm agree, we should leave it as it is and not localize it.
Helmut
Re: issue-#80 localizable menus
Posted: Tue Nov 24, 2015 3:05 pm
by Josef Templ
Zinn wrote:Hi Josef,
in DevInspector you fix a bug by adding a line behind Kernel.SplitName:
Kernel.SplitName(control, subs, cntr);
IF subs[LEN(subs$) - 1] = "." THEN (* no subsystem *) subs := "System"; cntr := control$ END;
Is it not better to insert this IF line into the procedure Kernel.SplitName itself?
Otherwise we have to do the same bug fix in 10 other modules too.
- Helmut
Yes and No.
Kernel.SplitName returns an empty subsystem ("") if there is no subsystem in the name. This cannot be changed.
What can be changed is that qualified names return an invalid subsystem instead of an empty subsystem.
The IF after Kernel.SplitName in DevInspector will still be needed for mapping an empty subsystem to "System" but the advantage is that it will work for ALL qualified names independent from the capitalization of the characters following the ".". In the current solution there may actually be cases that still don't work (e.g. Control.pushButton).
I have done this fix now.
For the changes see
http://redmine.blackboxframework.org/pr ... 42d4903625.
- Josef
Re: issue-#80 localizable menus
Posted: Tue Nov 24, 2015 10:00 pm
by Zinn
Hi Josef,
we need a convention to distinguish between menus entries and non menus entries inside the strings resource files.
Otherwise we always get the problem about key not unique.
I propose to add always the letter & in front of a menus entries for solving the problem (instead to add sometimes _ behind).
This letter is also used to mark a letter inside the menu for underline this letter.
Another advantage is that in a sorted strings file the menu entries come first.
...
&Edit Edit
&Undo &Undo
&Redo R&edo
&Cut Cu&t
&Copy &Copy
&Paste &Paste
&Delete &Delete Delete
...
- Helmut
Re: issue-#80 localizable menus
Posted: Wed Nov 25, 2015 8:37 am
by Josef Templ
Zinn wrote:
we need a convention to distinguish between menus entries and non menus entries inside the strings resource files.
Otherwise we always get the problem about key not unique.
I propose to add always the letter & in front of a menus entries for solving the problem (instead to add sometimes _ behind).
This letter is also used to mark a letter inside the menu for underline this letter.
Another advantage is that in a sorted strings file the menu entries come first.
...
- Helmut
I like this proposal.
The only detail problem I see is with the "Delete" menu item, which appears twice in menu System.
Currently it is resolved by using "Del" and "Delete". Should we keep this distinction?
Before I make this change, which is a lot of editing, I would like to make sure that
the proposal will be accepted by the majority.
- Josef