From: Heikki Lehvaslaiho <heikki.lehvaslaiho@gmail.com>
To: "Sebastian Reuße" <seb@wirrsal.net>
Cc: emacs-orgmode@gnu.org, Nicolas Goaziou <mail@nicolasgoaziou.fr>
Subject: Re: bug: org-table-sort-lines does only case sensitive alphabetical sorting
Date: Tue, 17 Jul 2018 09:24:23 +0300 [thread overview]
Message-ID: <CAK=ukcbrRaKpOyFmSU6-LuDfbpRrmUdr6wMfTzOMT04zSh-y1w@mail.gmail.com> (raw)
In-Reply-To: <87efg6ov77.fsf@wirrsal.net>
[-- Attachment #1: Type: text/plain, Size: 2592 bytes --]
Thanks for replies,
I am using:
GNU Emacs 26.1 (build 1, x86_64-apple-darwin14.5.0, NS appkit-1348.17
Version 10.10.5 (Build 14F2511)) of 2018-05-31
This is what I get:
(string-collate-lessp "a" "x" "de_DE.utf-8" nil) ; t
(string-collate-lessp "a" "X" "de_DE.utf-8" t) ; nil
(string-collate-lessp "a" "x" "fi_FI.utf-8" nil) ; t
(string-collate-lessp "a" "X" "fi_FI.utf-8" t) ; nil
I think I have lost the sense how Emacs language environments work
after struggling for years with buffers getting automatically
converted to Latin-1. I started setting all possible variables to
'UTF-8 and finally something did it.
Now I tried again various values to see if they affect the org table
sorting:
(set-language-environment 'utf-8)
(set-language-environment 'English)
(set-language-environment 'Swedish)
(setq locale-coding-system 'utf-8)
(setq locale-coding-system 'fi_FI.utf-8)
(setq locale-coding-system 'de_DE.utf-8)
(setq locale-coding-system 'en_GB.utf-8)
Unfortunately none of these made any difference. Any suggestions?
I am testing sorting in a simple one column table:
| a |
| c |
| B |
| D |
-Heikki
Heikki Lehväslaiho - skype:heikki_lehvaslaiho cell: +358 40 850 6640
http://about.me/heikki
On 14 July 2018 at 15:31, Sebastian Reuße <seb@wirrsal.net> wrote:
> Hello Nicolas, hello Heikki,
>
> > Heikki Lehvaslaiho <heikki.lehvaslaiho@gmail.com> writes:
>
> >> I can not see any change in function with the new code. Alphabetical
> >> sorting is fixedly case sensitive.
>
> Is your Emacs≤24? Emacs (surprisingly) only gained a facility for
> alphabetic (locale-sensitive) sorting with ver. 25. Before that, we will
> resort to using «string-lessp», which only sorts lexicographically (i.e,
> based on the binary character value, which means it is always
> case-sensitive on Unicode systems).
>
> If you are using GNU Emacs≥25, what locale are you using? FI_fi and most
> of the other western locales are based on ISO-14651, so you should
> always get case-*in*sensitive orderings, which is what I get with Emacs
> 26.1. So, evaluating the following should all yield «t»:
>
> (string-collate-lessp "a" "x" "de_DE.utf-8" nil)
> (string-collate-lessp "a" "X" "de_DE.utf-8" t)
> (string-collate-lessp "a" "x" "fi_FI.utf-8" nil)
> (string-collate-lessp "a" "X" "fi_FI.utf-8" t)
>
> Kind regards,
>
> Sebastian
>
> --
> Insane cobra split the wood
> Trader of the lowland breed
> Call a jittney, drive away
> In the slipstream we will stay
>
[-- Attachment #2: Type: text/html, Size: 3992 bytes --]
next prev parent reply other threads:[~2018-07-17 6:24 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-03 9:21 bug: org-table-sort-lines does only case sensitive alphabetical sorting Heikki Lehvaslaiho
2018-07-04 16:16 ` Nicolas Goaziou
2018-07-12 6:58 ` Heikki Lehvaslaiho
2018-07-14 9:10 ` Nicolas Goaziou
2018-07-14 12:31 ` Sebastian Reuße
2018-07-17 6:24 ` Heikki Lehvaslaiho [this message]
2018-07-17 6:59 ` Sebastian Reuße
2018-07-19 7:29 ` Heikki Lehvaslaiho
2018-07-19 11:20 ` Sebastian Reuße
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAK=ukcbrRaKpOyFmSU6-LuDfbpRrmUdr6wMfTzOMT04zSh-y1w@mail.gmail.com' \
--to=heikki.lehvaslaiho@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=mail@nicolasgoaziou.fr \
--cc=seb@wirrsal.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).