Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #204473 > unrolled thread

customise internationalization

Started byAndreas Berglund <email.lists81@gmail.com>
First post2019-01-16 23:40 +0100
Last post2019-01-18 22:20 +0100
Articles 7 — 5 participants

Back to article view | Back to linux.debian.user


Contents

  customise internationalization Andreas Berglund <email.lists81@gmail.com> - 2019-01-16 23:40 +0100
    Re: customise internationalization Roberto C. Sánchez <roberto@debian.org> - 2019-01-16 23:50 +0100
      Re: customise internationalization Greg Wooledge <wooledg@eeg.ccf.org> - 2019-01-17 14:20 +0100
        Re: customise internationalization email.lists81@gmail.com - 2019-01-17 22:00 +0100
          Re: customise internationalization Greg Wooledge <wooledg@eeg.ccf.org> - 2019-01-17 22:00 +0100
            Re: customise internationalization Dan Purgert <dan@djph.net> - 2019-01-17 22:20 +0100
            Re: customise internationalization email.lists81@gmail.com - 2019-01-18 22:20 +0100

#204473 — customise internationalization

FromAndreas Berglund <email.lists81@gmail.com>
Date2019-01-16 23:40 +0100
Subjectcustomise internationalization
Message-ID<xh20N-3Ut-5@gated-at.bofh.it>
Hi!

I have Swedish language settings. I would like to partly change those. I 
want Swedish keyboard settings and all the date formats, currency, 
thousands separators, decimals and so on to conform to Swedish 
convention. But in programs I want all menus, messages, error messages 
etc in English. Is this doable, if so how?


regards

Andreas

[toc] | [next] | [standalone]


#204474

FromRoberto C. Sánchez <roberto@debian.org>
Date2019-01-16 23:50 +0100
Message-ID<xh2at-3XP-1@gated-at.bofh.it>
In reply to#204473
On Wed, Jan 16, 2019 at 11:38:52PM +0100, Andreas Berglund wrote:
> Hi!
> 
> I have Swedish language settings. I would like to partly change those. I
> want Swedish keyboard settings and all the date formats, currency, thousands
> separators, decimals and so on to conform to Swedish convention. But in
> programs I want all menus, messages, error messages etc in English. Is this
> doable, if so how?
> 
Have a look at the locale(7) man page.  It describes macros for use by a
programmer, but each of those macros also corresponds to an environment
variable.  You can accomplish what you describe by settting all the LC_*
variables (or perhaps LC_ALL) to your Swedish locale and then setting
LANG to an English language locale.

Regards,

-Roberto

-- 
Roberto C. Sánchez

[toc] | [prev] | [next] | [standalone]


#204490

FromGreg Wooledge <wooledg@eeg.ccf.org>
Date2019-01-17 14:20 +0100
Message-ID<xhfKp-4bA-7@gated-at.bofh.it>
In reply to#204474
On Wed, Jan 16, 2019 at 05:45:58PM -0500, Roberto C. Sánchez wrote:
> On Wed, Jan 16, 2019 at 11:38:52PM +0100, Andreas Berglund wrote:
> > Hi!
> > 
> > I have Swedish language settings. I would like to partly change those. I
> > want Swedish keyboard settings and all the date formats, currency, thousands
> > separators, decimals and so on to conform to Swedish convention. But in
> > programs I want all menus, messages, error messages etc in English. Is this
> > doable, if so how?
> > 
> Have a look at the locale(7) man page.  It describes macros for use by a
> programmer, but each of those macros also corresponds to an environment
> variable.  You can accomplish what you describe by settting all the LC_*
> variables (or perhaps LC_ALL) to your Swedish locale and then setting
> LANG to an English language locale.

Not LC_ALL.  That would override LANG.

export LANG=en_US.utf8          # or en_GB or whatever you prefer
export LC_TIME=sv_SE.utf8
export LC_MONETARY=sv_SE.utf8
export LC_NUMERIC=sv_SE.utf8

You'll have to figure out *where* to do this, and that will depend on
how you login to the system, and also on whether you run some kind of
Desktop Environment that will clobber your environment settings.

[toc] | [prev] | [next] | [standalone]


#204498

Fromemail.lists81@gmail.com
Date2019-01-17 22:00 +0100
Message-ID<xhmVz-8nC-1@gated-at.bofh.it>
In reply to#204490
On 2019-01-17 14:12, Greg Wooledge wrote:
> On Wed, Jan 16, 2019 at 05:45:58PM -0500, Roberto C. Sánchez wrote:
>> On Wed, Jan 16, 2019 at 11:38:52PM +0100, Andreas Berglund wrote:
>>> Hi!
>>>
>>> I have Swedish language settings. I would like to partly change those. I
>>> want Swedish keyboard settings and all the date formats, currency, thousands
>>> separators, decimals and so on to conform to Swedish convention. But in
>>> programs I want all menus, messages, error messages etc in English. Is this
>>> doable, if so how?
>>>
>> Have a look at the locale(7) man page.  It describes macros for use by a
>> programmer, but each of those macros also corresponds to an environment
>> variable.  You can accomplish what you describe by settting all the LC_*
>> variables (or perhaps LC_ALL) to your Swedish locale and then setting
>> LANG to an English language locale.
> Not LC_ALL.  That would override LANG.
>
> export LANG=en_US.utf8          # or en_GB or whatever you prefer
> export LC_TIME=sv_SE.utf8
> export LC_MONETARY=sv_SE.utf8
> export LC_NUMERIC=sv_SE.utf8
>
> You'll have to figure out *where* to do this, and that will depend on
> how you login to the system, and also on whether you run some kind of
> Desktop Environment that will clobber your environment settings.
>
Thanks for the help.

That was going to be my next question. I use lightdm to login in to KDE. 
I was thinking I'd put it in ~/.bashrc for the shell and either 
~/.xsessionrc or ~/.dmrc for the desktop environment?

[toc] | [prev] | [next] | [standalone]


#204499

FromGreg Wooledge <wooledg@eeg.ccf.org>
Date2019-01-17 22:00 +0100
Message-ID<xhmVA-8nC-11@gated-at.bofh.it>
In reply to#204498
On Thu, Jan 17, 2019 at 09:50:01PM +0100, email.lists81@gmail.com wrote:
> That was going to be my next question. I use lightdm to login in to KDE. I
> was thinking I'd put it in ~/.bashrc for the shell and either ~/.xsessionrc
> or ~/.dmrc for the desktop environment?

Try .xsessionrc and see if that works.  The questions will be:

(1) Does KDE overwrite your variables?
(2) Are your terminals launched as children of the KDE window manager, or
    are they spawned from the pits of hell like GNOME does it?

Maybe you'll get "lucky" and .xsessionrc will simply work, and then you'll
be done.  I don't know, but it's worth a try, before you go diving into
the realms of the primordial gods.

[toc] | [prev] | [next] | [standalone]


#204500

FromDan Purgert <dan@djph.net>
Date2019-01-17 22:20 +0100
Message-ID<xhneV-i7-5@gated-at.bofh.it>
In reply to#204499
Greg Wooledge wrote:
> [...]
> I don't know, but it's worth a try, before you go diving into
> the realms of the primordial gods.

But jiw else are we to wake Cthulhu? :)

-- 
|_|O|_| Registered Linux user #585947
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: 05CA 9A50 3F2E 1335 4DC5  4AEE 8E11 DDF3 1279 A281

[toc] | [prev] | [next] | [standalone]


#204521

Fromemail.lists81@gmail.com
Date2019-01-18 22:20 +0100
Message-ID<xhJIu-5LH-5@gated-at.bofh.it>
In reply to#204499
On 2019-01-17 21:56, Greg Wooledge wrote:
> On Thu, Jan 17, 2019 at 09:50:01PM +0100, email.lists81@gmail.com wrote:
>> That was going to be my next question. I use lightdm to login in to KDE. I
>> was thinking I'd put it in ~/.bashrc for the shell and either ~/.xsessionrc
>> or ~/.dmrc for the desktop environment?
> Try .xsessionrc and see if that works.  The questions will be:
>
> (1) Does KDE overwrite your variables?
> (2) Are your terminals launched as children of the KDE window manager, or
>      are they spawned from the pits of hell like GNOME does it?
It seems that the following process relationships hold init->konsole->bash
>
> Maybe you'll get "lucky" and .xsessionrc will simply work, and then you'll
> be done.  I don't know, but it's worth a try, before you go diving into
> the realms of the primordial gods.

I think I got lucky, putting things in ~/.xsessionrc seems to have 
worked :)

[toc] | [prev] | [standalone]


Back to top | Article view | linux.debian.user


csiph-web