Re: Text hyphenation

2011-10-01 Thread Arthur Reutenauer
On Wed, Sep 28, 2011 at 05:31:31PM +0200, Werner LEMBERG wrote: For hyphenation, there exists the libhyphen library (used e.g. in OpenOffice). It implements the original hyphenation algorithm of TeX with extensions (I don't know what those are), but it does not have the rules for hyphenating

Re: Text hyphenation

2011-10-01 Thread David Kastrup
Arthur Reutenauer arthur.reutena...@normalesup.org writes: On Wed, Sep 28, 2011 at 05:31:31PM +0200, Werner LEMBERG wrote: For hyphenation, there exists the libhyphen library (used e.g. in OpenOffice). It implements the original hyphenation algorithm of TeX with extensions (I don't know

Re: Text hyphenation

2011-09-28 Thread Werner LEMBERG
Now, what is better between '--' and '\-': '--' stands for an en dash in many languages. I proposed to use it in the list of special characters I just pushed, but we decided to use ndash; instead, because '--' already stands for hyphenation in the lyrics. As Janek said, if we want to make

Re: Text hyphenation

2011-09-28 Thread Bertrand Bordage
2011/9/28 Werner LEMBERG w...@gnu.org If at all, please use a more decent, *single* character instead of `--'. What about `='? Not that I'm very happy with it, but... Then we could also add `|' to inhibit ligatures (which is quite important in German): Auf|lagen=steigerung Very good

Re: Text hyphenation

2011-09-28 Thread Reinhold Kainhofer
Am Mittwoch, 28. September 2011, 13:34:01 schrieb Bertrand Bordage: 2011/9/28 Werner LEMBERG w...@gnu.org If at all, please use a more decent, *single* character instead of `--'. What about `='? Not that I'm very happy with it, but... Then we could also add `|' to inhibit ligatures

Re: Text hyphenation

2011-09-28 Thread Janek Warchoł
2011/9/28 Werner LEMBERG w...@gnu.org: I really, really dislike `--' within a textual environment.  Remember that you aren't going to enter such a soft hyphen character very often since it is necessary only in the cases where (yet-to-be-implemented) automatic hyphenation fails or gives

Re: Text hyphenation

2011-09-28 Thread Werner LEMBERG
I use both | and = regularly in markup. [...] Ah, OK. I like the \- (without whitespace) most, as this is also LaTeX' s way to allow (but not force) a line break. BTW, in analogy to LaTeX's german.sty, the following would be useful also: \ a zero-width breakpoint not causing a hyphen,

Re: Text hyphenation

2011-09-28 Thread Werner LEMBERG
If i understood correctly (user can type '--' in his file and than search-and-replace it to '\-' ), that's anti-usability and anti-userfrindliness at it's best. Hehe. No comment :-) I will keep repeating (sorry): better change lyric hyphen command than use different commands for lyric

Re: Text hyphenation

2011-09-28 Thread Werner LEMBERG
It would be awesome if LilyPond had many of the functionalities of LaTeX, but it'd be a pity if we spent developer time implementing a host of LaTeX-like functionality from scratch when LaTeX already exists. Well, we don't want to imitate LaTeX, but naturally the same problem appears, namely

Re: Text hyphenation

2011-09-28 Thread m...@apollinemike.com
On Sep 28, 2011, at 5:31 PM, Werner LEMBERG wrote: It would be awesome if LilyPond had many of the functionalities of LaTeX, but it'd be a pity if we spent developer time implementing a host of LaTeX-like functionality from scratch when LaTeX already exists. Well, we don't want to

Re: Text hyphenation

2011-09-28 Thread m...@apollinemike.com
On Sep 28, 2011, at 4:33 PM, Werner LEMBERG wrote: If i understood correctly (user can type '--' in his file and than search-and-replace it to '\-' ), that's anti-usability and anti-userfrindliness at it's best. Hehe. No comment :-) I will keep repeating (sorry): better change lyric

Re: Text hyphenation

2011-09-28 Thread David Kastrup
Werner LEMBERG w...@gnu.org writes: If i understood correctly (user can type '--' in his file and than search-and-replace it to '\-' ), that's anti-usability and anti-userfrindliness at it's best. Hehe. No comment :-) I will keep repeating (sorry): better change lyric hyphen command than

Re: Text hyphenation

2011-09-28 Thread Bertrand Bordage
@Dak: Yes, that would be perfect if everything could be defined so easily. I guess this still requires a lot of work on the parser (yours are awesome, besides!). @Mike: Using pango and libhyphen would definitely be better. I'm therefore waiting for our « coding par-tay!!1 »! Bertrand

Re: Text hyphenation

2011-09-28 Thread David Kastrup
Bertrand Bordage bordage.bertr...@gmail.com writes: @Dak: Yes, that would be perfect if everything could be defined so easily.  I guess this still requires a lot of work on the parser I don't think so. It is the lexer that would need change, and not all that much. You'd have to define music

Re: Text hyphenation

2011-09-25 Thread Janek Warchoł
2011/9/24 Bertrand Bordage bordage.bertr...@gmail.com: 2011/9/23 Janek Warchoł janek.lilyp...@gmail.com Hi Bertrand, 2011/9/23 Bertrand Bordage bordage.bertr...@gmail.com: * making a system that allows to specify where a word is breakable (like \- in LaTeX); I vote for this because it

Re: Text hyphenation

2011-09-25 Thread Bertrand Bordage
This would require some work on the parser/lexer, but I think it is possible to do. The example you wrote seems a bit messy to me. It is better to keep the lyricmode: someText = lyricmode { some4 de8 -- mon16 -- stra -- tion4 text, hoo -- ray! } \markup \someText \new Lyrics \someText I don't

Re: Text hyphenation

2011-09-25 Thread Werner LEMBERG
I worked on this yesterday. I chose '--' instead of '\-'. The result is great (see attached). Mhmm. Normally, in plain text, even in non-TeX related contexts, `--' means an en-dash or em-dash. I *much* prefer `\-'. Maybe it could work like -- in lyrics? I mean, it would be nice to be

Re: Text hyphenation

2011-09-25 Thread Janek Warchoł
2011/9/25 Werner LEMBERG w...@gnu.org: I worked on this yesterday. I chose '--' instead of '\-'. The result is great (see attached). Mhmm.  Normally, in plain text, even in non-TeX related contexts, `--' means an en-dash or em-dash.  I *much* prefer `\-'. Maybe it could work like -- in

Re: Text hyphenation

2011-09-25 Thread Werner LEMBERG
I don't like it, since it is extremely unnatural to me if applied to longer texts.  Instead, I would prefer a simple Scheme function which converts `foo -- bar' into `foo\-bar' if desired. I'd prefer changing lyric hyphen command from -- to \- instead of creating such dichotomy. Hmm. Not

Re: Text hyphenation

2011-09-25 Thread Janek Warchoł
2011/9/25 Werner LEMBERG w...@gnu.org: Think about new users, they would be confused by this.  We should never make things more complicated than they must be, Lily is already too messy. Actually, we don't *need* `\-' at all since Unicode already provides characters to control hyphenation:

Re: Text hyphenation

2011-09-25 Thread Bertrand Bordage
2011/9/25 Werner LEMBERG w...@gnu.org Actually, we don't *need* `\-' at all since Unicode already provides characters to control hyphenation: 00ADSOFT HYPHEN 2010HYPHEN 2011NON-BREAKING HYPHEN Bertrand, does your code work support them? Here is how it works for the

Re: Text hyphenation

2011-09-24 Thread Bertrand Bordage
2011/9/23 Janek Warchoł janek.lilyp...@gmail.com Hi Bertrand, 2011/9/23 Bertrand Bordage bordage.bertr...@gmail.com: * making a system that allows to specify where a word is breakable (like \- in LaTeX); I vote for this because it seems most multi-language friendly. I.e., implementing

Re: Text hyphenation

2011-09-24 Thread Peekay Ex
Hello, 2011/9/24 Bertrand Bordage bordage.bertr...@gmail.com: 2011/9/23 Janek Warchoł janek.lilyp...@gmail.com Hi Bertrand, 2011/9/23 Bertrand Bordage bordage.bertr...@gmail.com: * making a system that allows to specify where a word is breakable (like \- in LaTeX); I vote for this

Re: Text hyphenation

2011-09-24 Thread Trevor Daniels
Peekay wrote Saturday, September 24, 2011 12:22 PM 2011/9/24 Bertrand Bordage bordage.bertr...@gmail.com: I worked on this yesterday. I chose '--' instead of '\-'. The result is great (see attached). Hmm... breaking a 4 letter word into two over two lines? Splitting père is even worse -

Re: Text hyphenation

2011-09-24 Thread Bertrand Bordage
2011/9/24 Peekay Ex pkx1...@gmail.com Hmm... breaking a 4 letter word into two over two lines? The typesetter in me cringes slightly. Indeed, global rules would be great for absent-minded people like me... @Trevor : Yes, this was only a manual demonstration. Bertrand

Re: Text hyphenation

2011-09-22 Thread Janek Warchoł
Hi Bertrand, 2011/9/23 Bertrand Bordage bordage.bertr...@gmail.com: Hi everyone, I started working on automatic hyphenation (see the attached PDF). I rewrote wordwrap-stencils into a wordwrap-markups and it works great, but I do have a question before continuing. Do you think I should start