ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* [NTG-context] Ukrainian hyphenation?
@ 2023-07-18 22:36 Gerben Wierda
  2023-07-19  6:52 ` [NTG-context] " Hans Hagen
  0 siblings, 1 reply; 6+ messages in thread
From: Gerben Wierda @ 2023-07-18 22:36 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 1385 bytes --]

This file:

\setupinteraction
  [state=start,
   color=blue,
   style=bold]

\definefallbackfamily
  [archimate]
  [ss]
  [Helvetica]
  [preset=range:cyrillic,
   tf=style:light,
   it=style:lightoblique,
   bf=style:regular,
   bi=style:oblique,
   force=yes,
   rscale=1.0]
\definefontfamily [archimate] [ss] [Helvetica]
\setupbodyfont[archimate]

\starttext
\setuplanguage[en][patterns={ru}]\mainlanguage[ru]
{\framed[frame=on,align=flushleft,width=7cm]{Техніка здатна до фізичної поведінки (на відміну від інформаційної поведінки). Наприклад `Металургійний комбінат'.}}\\
\setuplanguage[ua][patterns={ua}]\mainlanguage[ua]
{\framed[frame=on,align=flushleft,width=7cm]{Техніка здатна до фізичної поведінки (на відміну від інформаційної поведінки). Наприклад `Металургійний комбінат'.}}\\

\stoptext

Hyphenates russian but not ukrainian. Why?

Gerben Wierda (LinkedIn <https://www.linkedin.com/in/gerbenwierda>, Mastodon <https://newsie.social/@gctwnl>)
R&A IT Strategy <https://ea.rna.nl/> (main site)
Book: Chess and the Art of Enterprise Architecture <https://ea.rna.nl/the-book/>
Book: Mastering ArchiMate <https://ea.rna.nl/the-book-edition-iii/>


[-- Attachment #1.2: Type: text/html, Size: 6346 bytes --]

[-- Attachment #2: Type: text/plain, Size: 495 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [NTG-context] Re: Ukrainian hyphenation?
  2023-07-18 22:36 [NTG-context] Ukrainian hyphenation? Gerben Wierda
@ 2023-07-19  6:52 ` Hans Hagen
  2023-07-19  6:58   ` Gerben Wierda
  0 siblings, 1 reply; 6+ messages in thread
From: Hans Hagen @ 2023-07-19  6:52 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 7/19/2023 12:36 AM, Gerben Wierda wrote:
> This file:
> 
> \setupinteraction
>    [state=start,
>     color=blue,
>     style=bold]
> 
> \definefallbackfamily
>    [archimate]
>    [ss]
>    [Helvetica]
>    [preset=range:cyrillic,
>     tf=style:light,
>     it=style:lightoblique,
>     bf=style:regular,
>     bi=style:oblique,
>     force=yes,
>     rscale=1.0]
> \definefontfamily [archimate] [ss] [Helvetica]
> \setupbodyfont[archimate]
> 
> \starttext
> \setuplanguage[en][patterns={ru}]\mainlanguage[ru]
> {\framed[frame=on,align=flushleft,width=7cm]{Техніка здатна до фізичної поведінки (на відміну від інформаційної поведінки). Наприклад `Металургійний комбінат'.}}\\
> \setuplanguage[ua][patterns={ua}]\mainlanguage[ua]
> {\framed[frame=on,align=flushleft,width=7cm]{Техніка здатна до фізичної поведінки (на відміну від інформаційної поведінки). Наприклад `Металургійний комбінат'.}}\\
> 
> \stoptext
> 
> Hyphenates russian but not ukrainian. Why?
If there was some magick like that going on it should be the reverse 
right now. That said,

\setupbodyfont[dejavu]

\startbuffer[sample]
Техніка здатна до фізичної поведінки (на відміну від інформаційної
поведінки). Наприклад `Металургійний комбінат'.
\stopbuffer

\starttext

\mainlanguage[ru] {\hsize3cm \getbuffer[sample]}

\mainlanguage[ua] {\hsize3cm \getbuffer[sample]}

\stoptext

hyphenates differently and eventually reports

   mkiv lua stats  > loaded patterns: en::1 ru::22 ua::23

so best not mess with setting up languages that already have been set up.

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [NTG-context] Re: Ukrainian hyphenation?
  2023-07-19  6:52 ` [NTG-context] " Hans Hagen
@ 2023-07-19  6:58   ` Gerben Wierda
  2023-07-19  7:17     ` Hans Hagen via ntg-context
  0 siblings, 1 reply; 6+ messages in thread
From: Gerben Wierda @ 2023-07-19  6:58 UTC (permalink / raw)
  To: mailing list for ConTeXt users



> On 19 Jul 2023, at 08:52, Hans Hagen <j.hagen@xs4all.nl> wrote:
> 
> so best not mess with setting up languages that already have been set up.

I had no idea I was messing. What am I doing wrong, then. Because in my actual document with ua language setting it is not hyphenated. This was just a minimal example 
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [NTG-context] Re: Ukrainian hyphenation?
  2023-07-19  6:58   ` Gerben Wierda
@ 2023-07-19  7:17     ` Hans Hagen via ntg-context
  2023-08-05 13:23       ` [NTG-context] \phrasetext issue with language uk. Was: " Gerben Wierda
  0 siblings, 1 reply; 6+ messages in thread
From: Hans Hagen via ntg-context @ 2023-07-19  7:17 UTC (permalink / raw)
  To: ntg-context; +Cc: Hans Hagen

On 7/19/2023 8:58 AM, Gerben Wierda wrote:
> 
> 
>> On 19 Jul 2023, at 08:52, Hans Hagen <j.hagen@xs4all.nl> wrote:
>>
>> so best not mess with setting up languages that already have been set up.
> 
> I had no idea I was messing. What am I doing wrong, then. Because in my actual document with ua language setting it is not hyphenated. This was just a minimal example

do you get something similar?

 >mtxrun lang-uk.lua
c:/data/develop/tex-context/tex/texmf-context/tex/context/patterns/mkiv/lang-uk.lua

uk is the offical tag but for historic reasone we use ua as language; 
given the uk's exit and ua's entry in the european union we could now 
consider adapting it; and i'd wonder is anyone would notice - or bother 
- is we'd use ukrain hyphenation for russian, which could save some 
bytes in the distribution

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [NTG-context] \phrasetext issue with language uk. Was: Ukrainian hyphenation?
  2023-07-19  7:17     ` Hans Hagen via ntg-context
@ 2023-08-05 13:23       ` Gerben Wierda
  2023-08-05 13:43         ` [NTG-context] " Gerben Wierda
  0 siblings, 1 reply; 6+ messages in thread
From: Gerben Wierda @ 2023-08-05 13:23 UTC (permalink / raw)
  To: mailing list for ConTeXt users



> On 19 Jul 2023, at 09:17, Hans Hagen via ntg-context <ntg-context@ntg.nl> wrote:
> 
> On 7/19/2023 8:58 AM, Gerben Wierda wrote:
>>> On 19 Jul 2023, at 08:52, Hans Hagen <j.hagen@xs4all.nl> wrote:
>>> 
>>> so best not mess with setting up languages that already have been set up.
>> I had no idea I was messing. What am I doing wrong, then. Because in my actual document with ua language setting it is not hyphenated. This was just a minimal example
> 
> do you get something similar?
> 
> >mtxrun lang-uk.lua
> c:/data/develop/tex-context/tex/texmf-context/tex/context/patterns/mkiv/lang-uk.lua
> 
> uk is the offical tag but for historic reasone we use ua as language; given the uk's exit and ua's entry in the european union we could now consider adapting it; and i'd wonder is anyone would notice - or bother - is we'd use ukrain hyphenation for russian, which could save some bytes in the distribution

Yes, that solved the hyphenation issue. But  now I am having trouble with \phrasetext. When using uk as language code, \phrasetext does not work.

So, use 'ua', \phrasetext works, but hyphenation does not
And use 'uk', hyphenation works, but \phrasetext does not

%==========================================
\definefallbackfamily
  [archimate]
  [ss]
  [Helvetica]
  [preset=range:cyrillic,
   tf=style:light,
   it=style:lightoblique,
   bf=style:regular,
   bi=style:oblique,
   force=yes,
   rscale=1.0]
\definefontfamily [archimate] [ss] [Helvetica]
\setupbodyfont[archimate]

\definelabelclass[phrase]
\setupphrasetext[en][sheettitle={ArchiMate® 3.2 Metamodel -- Core}]
\setupphrasetext[ru][sheettitle={Ядро метамодели ArchiMate® 3.2}]
\setupphrasetext[uk][sheettitle={Основні елементи метамоделі ArchiMate® 3.2}]
\setupphrasetext[ua][sheettitle={Основні елементи метамоделі ArchiMate® 3.2}]

\starttext
\setuplanguage[uk][patterns={uk}]\mainlanguage[uk]
\phrasetext{sheettitle}

\setuplanguage[ru][patterns={ru}]\mainlanguage[ru]
\phrasetext{sheettitle}

\setuplanguage[uk][patterns={uk}]\mainlanguage[uk]
\phrasetext{sheettitle}

\setuplanguage[ua][patterns={ua}]\mainlanguage[ua]
\phrasetext{sheettitle}
\stoptext
%==========================================
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [NTG-context] Re: \phrasetext issue with language uk. Was: Ukrainian hyphenation?
  2023-08-05 13:23       ` [NTG-context] \phrasetext issue with language uk. Was: " Gerben Wierda
@ 2023-08-05 13:43         ` Gerben Wierda
  0 siblings, 0 replies; 6+ messages in thread
From: Gerben Wierda @ 2023-08-05 13:43 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 3401 bytes --]

Basically, the situation then is, the language is called ua but the patterns are called uk?

> On 5 Aug 2023, at 15:23, Gerben Wierda <gerben.wierda@rna.nl> wrote:
> 
> 
> 
>> On 19 Jul 2023, at 09:17, Hans Hagen via ntg-context <ntg-context@ntg.nl> wrote:
>> 
>> On 7/19/2023 8:58 AM, Gerben Wierda wrote:
>>>> On 19 Jul 2023, at 08:52, Hans Hagen <j.hagen@xs4all.nl> wrote:
>>>> 
>>>> so best not mess with setting up languages that already have been set up.
>>> I had no idea I was messing. What am I doing wrong, then. Because in my actual document with ua language setting it is not hyphenated. This was just a minimal example
>> 
>> do you get something similar?
>> 
>>> mtxrun lang-uk.lua
>> c:/data/develop/tex-context/tex/texmf-context/tex/context/patterns/mkiv/lang-uk.lua
>> 
>> uk is the offical tag but for historic reasone we use ua as language; given the uk's exit and ua's entry in the european union we could now consider adapting it; and i'd wonder is anyone would notice - or bother - is we'd use ukrain hyphenation for russian, which could save some bytes in the distribution
> 
> Yes, that solved the hyphenation issue. But  now I am having trouble with \phrasetext. When using uk as language code, \phrasetext does not work.
> 
> So, use 'ua', \phrasetext works, but hyphenation does not
> And use 'uk', hyphenation works, but \phrasetext does not
> 
> %==========================================
> \definefallbackfamily
>  [archimate]
>  [ss]
>  [Helvetica]
>  [preset=range:cyrillic,
>   tf=style:light,
>   it=style:lightoblique,
>   bf=style:regular,
>   bi=style:oblique,
>   force=yes,
>   rscale=1.0]
> \definefontfamily [archimate] [ss] [Helvetica]
> \setupbodyfont[archimate]
> 
> \definelabelclass[phrase]
> \setupphrasetext[en][sheettitle={ArchiMate® 3.2 Metamodel -- Core}]
> \setupphrasetext[ru][sheettitle={Ядро метамодели ArchiMate® 3.2}]
> \setupphrasetext[uk][sheettitle={Основні елементи метамоделі ArchiMate® 3.2}]
> \setupphrasetext[ua][sheettitle={Основні елементи метамоделі ArchiMate® 3.2}]
> 
> \starttext
> \setuplanguage[uk][patterns={uk}]\mainlanguage[uk]
> \phrasetext{sheettitle}
> 
> \setuplanguage[ru][patterns={ru}]\mainlanguage[ru]
> \phrasetext{sheettitle}
> 
> \setuplanguage[uk][patterns={uk}]\mainlanguage[uk]
> \phrasetext{sheettitle}
> 
> \setuplanguage[ua][patterns={ua}]\mainlanguage[ua]
> \phrasetext{sheettitle}
> \stoptext
> %==========================================
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to the Wiki!
> 
> maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki     : https://contextgarden.net
> ___________________________________________________________________________________

Gerben Wierda (LinkedIn <https://www.linkedin.com/in/gerbenwierda>, Mastodon <https://newsie.social/@gctwnl>)
R&A IT Strategy <https://ea.rna.nl/> (main site)
Book: Chess and the Art of Enterprise Architecture <https://ea.rna.nl/the-book/>
Book: Mastering ArchiMate <https://ea.rna.nl/the-book-edition-iii/>


[-- Attachment #1.2: Type: text/html, Size: 8192 bytes --]

[-- Attachment #2: Type: text/plain, Size: 495 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-08-05 13:45 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-18 22:36 [NTG-context] Ukrainian hyphenation? Gerben Wierda
2023-07-19  6:52 ` [NTG-context] " Hans Hagen
2023-07-19  6:58   ` Gerben Wierda
2023-07-19  7:17     ` Hans Hagen via ntg-context
2023-08-05 13:23       ` [NTG-context] \phrasetext issue with language uk. Was: " Gerben Wierda
2023-08-05 13:43         ` [NTG-context] " Gerben Wierda

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 NNTP newsgroup(s).