The Trunk: GetText-kfr.35.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: GetText-kfr.35.mcz

commits-2
Karl Ramberg uploaded a new version of GetText to project The Trunk:
http://source.squeak.org/trunk/GetText-kfr.35.mcz

==================== Summary ====================

Name: GetText-kfr.35
Author: kfr
Time: 26 April 2015, 8:36:22.793 am
UUID: 850442bf-5dfd-6741-939c-4ff232aeabaf
Ancestors: GetText-nice.34

Make LanguageEditor items from TheWorldMenu/open respond a little nicer

=============== Diff against GetText-nice.34 ===============

Item was changed:
  ----- Method: LanguageEditor class>>on: (in category 'instance creation') -----
  on: localeID
  "answer an instance of the receiver on aLanguage"
  ^ self new
  initializeOn: (InternalTranslator cachedTranslations
  at: localeID
  ifAbsent: [self
+ inform: ('Translator for {1} is not found' translated format: {localeID}). ^nil])!
- error: ('Translator for {1} is not found' translated format: {localeID})])!

Item was changed:
  ----- Method: LanguageEditor class>>open (in category 'opening') -----
  open
  "open the receiver on any language"
  "
  LanguageEditor open.
  "
+ | menu availableLanguages |
- | menu |
  menu := MenuMorph new defaultTarget: self.
  menu addTitle: 'Language Editor for...' translated.
  ""
+ availableLanguages := (InternalTranslator availableLanguageLocaleIDs asSortedCollection: [:x :y | x asString <= y asString]).
+ availableLanguages ifEmpty:[^self inform:'InternalTranslator not initialized'].
+ availableLanguages
- (InternalTranslator availableLanguageLocaleIDs
- asSortedCollection: [:x :y | x asString <= y asString])
  do: [:eachLanguage | ""
  menu
  add: eachLanguage name
  target: self
  selector: #openOn:
  argument: eachLanguage].
  ""
  menu popUpInWorld!

Item was changed:
  ----- Method: LanguageEditor class>>openOn: (in category 'instance creation') -----
  openOn: aLanguage
  "open an instance on aLanguage"
+ | editor |
  World submorphs
  do: [:each | ""
  ((each isKindOf: LanguageEditor)
  and: [each translator == aLanguage])
  ifTrue: [""
  self ensureVisibilityOfWindow: each.
  ^ self]].
  ""
+ editor := self on: aLanguage.
+ editor ifNotNil:[^editor openInWorld]!
- ^ (self on: aLanguage) openInWorld!


Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: GetText-kfr.35.mcz

marcel.taeumel (old)
How to use the LanguageEditor?

Best,
Marcel
Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: GetText-kfr.35.mcz

Karl Ramberg
Hi,
I don't know how this works.
The whole translator system seem pretty broken, as far as I can tell.

Karl

On Sun, Apr 26, 2015 at 10:48 AM, Marcel Taeumel <[hidden email]> wrote:
How to use the LanguageEditor?

Best,
Marcel



--
View this message in context: http://forum.world.st/The-Trunk-GetText-kfr-35-mcz-tp4821914p4821924.html
Sent from the Squeak - Dev mailing list archive at Nabble.com.




Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: GetText-kfr.35.mcz

Karl Ramberg
I know translating was heavily used in the Squeakland Etoys image. There it seems the LanguageEditor is removed. I think translating was done on exported .mo files. I never looked at that part of the system, so I really don't know.

Bert should know much more about i18n & l10n of the Etoys

Karl


On Sun, Apr 26, 2015 at 12:00 PM, karl ramberg <[hidden email]> wrote:
Hi,
I don't know how this works.
The whole translator system seem pretty broken, as far as I can tell.

Karl

On Sun, Apr 26, 2015 at 10:48 AM, Marcel Taeumel <[hidden email]> wrote:
How to use the LanguageEditor?

Best,
Marcel



--
View this message in context: http://forum.world.st/The-Trunk-GetText-kfr-35-mcz-tp4821914p4821924.html
Sent from the Squeak - Dev mailing list archive at Nabble.com.





Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: GetText-kfr.35.mcz

marcel.taeumel (old)
Well, most literal strings have #translated attached to them. A convenient editor/translator would be nice.

http://doc.qt.io/qt-5/qtlinguist-index.html

Best,
Marcel
Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: GetText-kfr.35.mcz

Karl Ramberg
The LanguageEditor in the image is defunct. Maybe it can be resurrected and made usable, but I'm not sure there is any interest in doing that.

Karl

On Sun, Apr 26, 2015 at 2:30 PM, Marcel Taeumel <[hidden email]> wrote:
Well, most literal strings have #translated attached to them. A convenient
editor/translator would be nice.

http://doc.qt.io/qt-5/qtlinguist-index.html

Best,
Marcel



--
View this message in context: http://forum.world.st/The-Trunk-GetText-kfr-35-mcz-tp4821914p4821938.html
Sent from the Squeak - Dev mailing list archive at Nabble.com.




Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: GetText-kfr.35.mcz

marcel.taeumel (old)
Well, it is quite a simple tool... :) Maybe für Squeak 4.7. :D

Best,
Marcel
Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: GetText-kfr.35.mcz

Bert Freudenberg

> On 27.04.2015, at 03:54, Marcel Taeumel <[hidden email]> wrote:
>
> Well, it is quite a simple tool... :) Maybe für Squeak 4.7. :D
>
> Best,
> Marcel

The LanguageEditor is a remnant from the translation system before we switched to PO/MO files.

The current translation files are hosted at
        http://etoys.squeak.org/svn/trunk/po/

and compiled to MO format using gettext:
        https://www.gnu.org/software/gettext/

The editor could be resurrected, but it would only make sense if it was changed to work on PO files.

- Bert -






smime.p7s (5K) Download Attachment