LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices


Reply
  Search this Thread
Old 08-31-2007, 09:53 AM   #1
ovidnet
LQ Newbie
 
Registered: Mar 2006
Location: Longueuil, Quebec
Distribution: Slackware, Ubuntu, Slax
Posts: 13

Rep: Reputation: 0
multilanguage filename characters issue


I have a Slackware linux used as a Desktop.
I often use this machine to mount windows partitions (fat32, ntfs) and copy files from. Scenario is i copy files from damaged windows instalations, and source files can be in different languages, typical in french.

For example, the original file is
Mes fichiers reçus
and after copy became
Mes fichiers reçus

I want to keep english instalaton of slackware (Bluewhite64)
The question is how can I control charset for filenames, and if I can add multilanguage support, or if I can't, how can I switch settings for system. I don't want to use a conversion tool, in want to use system settings.

(for copy I used cp or F5 in MC)

http://www.linuxquestions.org/questi...d.php?t=382914 is a related post, but I'm not satisfied by response.
 
Old 08-31-2007, 03:25 PM   #2
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
The only way to use filenames from different codepages is naming them in utf8 codeset. You should install a utf8 locale - something like en_US.UTF8 - to do it.
 
Old 08-31-2007, 09:29 PM   #3
ovidnet
LQ Newbie
 
Registered: Mar 2006
Location: Longueuil, Quebec
Distribution: Slackware, Ubuntu, Slax
Posts: 13

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Samotnik View Post
You should install a utf8 locale - something like en_US.UTF8 - to do it.
ok, how to do this ?
where is located packages with locales ?
how can I switch locales ?
 
Old 10-10-2007, 02:38 PM   #4
ovidnet
LQ Newbie
 
Registered: Mar 2006
Location: Longueuil, Quebec
Distribution: Slackware, Ubuntu, Slax
Posts: 13

Original Poster
Rep: Reputation: 0
i use export locales fr_CA.UTF8 but is working only in X (KDE) not in command line (mc)
 
Old 10-10-2007, 03:10 PM   #5
Su-Shee
Member
 
Registered: Sep 2007
Location: Berlin
Distribution: Slackware
Posts: 510

Rep: Reputation: 53
Slackware has already got included all Unicode locales necessary.

I mix certain german locale settings with english settings this way - just exchange de_DE to ca_FR:

export LC_CTYPE="de_DE.utf-8"
export LC_COLLATE="de_DE.utf-8"
export LANG=en_US.utf-8
export LC_PAPER="de_DE.utf-8"

(mutt, less, vim require own settings but support Unicode perfectly fine.)

This leads to the result that I still get english messages and error messages and things like that, but a german alphabetical correct sort order and a german character set (no accents but umlauts) all encoded in UTF-8 Unicode.

Of course, I have to make sure my X font supports all this.

Under the command line without X, you'll have to use a different setting which is mostly a font issue.

Anyhow, I usally don't use unicode on the console, but mc within an xterm which supports Unicode does work properly, moves and deletes files and so on. I've just tried some random chinese filename.

After a short Google, I'd say "man setfont" might help you with the console.

In your case, you might have another problem: Windows encodes Unicode not in UTF-8 but in UTF-forgotwhichone and its files contain possibly a so callod BOM (byte order marker) to indicate some Unicode stuff I usally ignore, because Linux uses UTF-8. In that case you'll have to convert the file with iconv or another tool.

Last edited by Su-Shee; 10-10-2007 at 03:12 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Trying to delete a filename with special characters Harry Seldon Linux - General 11 03-20-2007 01:31 PM
Multilanguage Keyboard setup AlgebraicSpore Linux - Hardware 2 02-28-2006 06:38 PM
File Copy Issue-Special Characters fortezza Linux - Software 1 11-14-2005 07:16 AM
Chinese Filename Issue - Fedora Core 2 matthewchin Fedora - Installation 0 09-02-2004 08:44 PM
Special characters issue Agifem Linux - General 4 09-17-2003 12:42 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 06:49 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration