ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Persian interface
@ 2008-10-21 13:24 Mehdi Omidali
  2008-10-21 14:44 ` Hans Hagen
  0 siblings, 1 reply; 6+ messages in thread
From: Mehdi Omidali @ 2008-10-21 13:24 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi everyone,
I want to be able to use persian interface in context. So I tried to
create two files cont-pe.xml and cont-pe.tex for this purpose. Now my
questions are:
1- Am I supposed to just create these two files and then run context
--make cont-pe.
2- Can context accept these two files in UTF-8 encoding.
Thanks
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Persian interface
  2008-10-21 13:24 Persian interface Mehdi Omidali
@ 2008-10-21 14:44 ` Hans Hagen
  2008-10-23  4:31   ` Mehdi Omidali
  0 siblings, 1 reply; 6+ messages in thread
From: Hans Hagen @ 2008-10-21 14:44 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Mehdi Omidali wrote:
> Hi everyone,
> I want to be able to use persian interface in context. So I tried to
> create two files cont-pe.xml and cont-pe.tex for this purpose. Now my
> questions are:
> 1- Am I supposed to just create these two files and then run context
> --make cont-pe.
> 2- Can context accept these two files in UTF-8 encoding.

you need to adapt mult-con and mult-com but at the same time we need to 
adapt mult-sys, so as an experiment if things work out ok, just play a 
bit with mult-con/com e.g. replace a few harmless commands in the 
english interface and see if things work ok for persian

footnote: voetnoot                         footnote
           fussnote                         poznamkapodcarou
           notapdp                          notasubsol
           notepdp


eventually persian can become the 8th entry

footnote: voetnoot                         somethingpersian
           fussnote                         poznamkapodcarou
           notapdp                          notasubsol
           notepdp


\somethingpersian then should give you a footnote

(we never really tested it with utf8 input so far)

(when i have time i will (for luatex) make this mechanism different i.e. 
just lua tables from which i then can generate the con/com files)



-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | 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 / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Persian interface
  2008-10-21 14:44 ` Hans Hagen
@ 2008-10-23  4:31   ` Mehdi Omidali
  2008-10-23  6:43     ` Wolfgang Schuster
  0 siblings, 1 reply; 6+ messages in thread
From: Mehdi Omidali @ 2008-10-23  4:31 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 10/21/08, Hans Hagen <pragma@wxs.nl> wrote:
> Mehdi Omidali wrote:
>> Hi everyone,
>> I want to be able to use persian interface in context. So I tried to
>> create two files cont-pe.xml and cont-pe.tex for this purpose. Now my
>> questions are:
>> 1- Am I supposed to just create these two files and then run context
>> --make cont-pe.
>> 2- Can context accept these two files in UTF-8 encoding.
>
> you need to adapt mult-con and mult-com but at the same time we need to
> adapt mult-sys, so as an experiment if things work out ok, just play a
> bit with mult-con/com e.g. replace a few harmless commands in the
> english interface and see if things work ok for persian
>
> footnote: voetnoot                         footnote
>            fussnote                         poznamkapodcarou
>            notapdp                          notasubsol
>            notepdp
>
>
> eventually persian can become the 8th entry
>
> footnote: voetnoot                         somethingpersian
>            fussnote                         poznamkapodcarou
>            notapdp                          notasubsol
>            notepdp
>
>
> \somethingpersian then should give you a footnote
>
> (we never really tested it with utf8 input so far)
>
> (when i have time i will (for luatex) make this mechanism different i.e.
> just lua tables from which i then can generate the con/com files)
Hi Hans and everybody,
I did as you said and saw two things.
1- The good news: it is possible to assign another name (even persian)
for an option name. For example the word "packed" which is used as an
option in some commands like \setupitemize works well if you
substitute it with anything.
2- The bad news: names of commands (I mean words that is used in the
input file with a backslash in front of them like footnote or
setupsomething) are not well behaved if we change them in
mult.con.tex. I tried to change for example the word "footnote" with a
persian word with more than one character and in the running time I
got the error that that command is not defined. But I was able to
redefine footnote with a just one (persian) character.
Thanks
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Persian interface
  2008-10-23  4:31   ` Mehdi Omidali
@ 2008-10-23  6:43     ` Wolfgang Schuster
  2008-10-23 13:11       ` Hans Hagen
  0 siblings, 1 reply; 6+ messages in thread
From: Wolfgang Schuster @ 2008-10-23  6:43 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Thu, Oct 23, 2008 at 6:31 AM, Mehdi Omidali <mehdioa@gmail.com> wrote:
> On 10/21/08, Hans Hagen <pragma@wxs.nl> wrote:
>> Mehdi Omidali wrote:
>>> Hi everyone,
>>> I want to be able to use persian interface in context. So I tried to
>>> create two files cont-pe.xml and cont-pe.tex for this purpose. Now my
>>> questions are:
>>> 1- Am I supposed to just create these two files and then run context
>>> --make cont-pe.
>>> 2- Can context accept these two files in UTF-8 encoding.
>>
>> you need to adapt mult-con and mult-com but at the same time we need to
>> adapt mult-sys, so as an experiment if things work out ok, just play a
>> bit with mult-con/com e.g. replace a few harmless commands in the
>> english interface and see if things work ok for persian
>>
>> footnote: voetnoot                         footnote
>>            fussnote                         poznamkapodcarou
>>            notapdp                          notasubsol
>>            notepdp
>>
>>
>> eventually persian can become the 8th entry
>>
>> footnote: voetnoot                         somethingpersian
>>            fussnote                         poznamkapodcarou
>>            notapdp                          notasubsol
>>            notepdp
>>
>>
>> \somethingpersian then should give you a footnote
>>
>> (we never really tested it with utf8 input so far)
>>
>> (when i have time i will (for luatex) make this mechanism different i.e.
>> just lua tables from which i then can generate the con/com files)
> Hi Hans and everybody,
> I did as you said and saw two things.
> 1- The good news: it is possible to assign another name (even persian)
> for an option name. For example the word "packed" which is used as an
> option in some commands like \setupitemize works well if you
> substitute it with anything.
> 2- The bad news: names of commands (I mean words that is used in the
> input file with a backslash in front of them like footnote or
> setupsomething) are not well behaved if we change them in
> mult.con.tex. I tried to change for example the word "footnote" with a
> persian word with more than one character and in the running time I
> got the error that that command is not defined. But I was able to
> redefine footnote with a just one (persian) character.

You need characters with catcode 11 for the commands and most of the
chars outside the ASCII range have catcode 12 which can be used only
in commands with the length 1 like your footnote example.

Here is a example how to use umlauts for the german interface:

\catcode`ü=11

\startcommands                    dutch                            english
                                  german                           czech
                                  italian                          romanian
                                  french

                                  definittete
                       setuphead: stelkopin                        setuphead
                                  stelleüberschriftein             nastavnadpis
                                  impostatesta                     seteazatitlu
                                  regletete

\stopcommands

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

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Persian interface
  2008-10-23  6:43     ` Wolfgang Schuster
@ 2008-10-23 13:11       ` Hans Hagen
  0 siblings, 0 replies; 6+ messages in thread
From: Hans Hagen @ 2008-10-23 13:11 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Wolfgang Schuster wrote:

> You need characters with catcode 11 for the commands and most of the
> chars outside the ASCII range have catcode 12 which can be used only
> in commands with the length 1 like your footnote example.

hm, maybe the catcode initialization takes place too late

> Here is a example how to use umlauts for the german interface:

in the next beta this system is replaced by another one:

- mult-def.lua

this is a table that has all variables, constants, elements and commands 
in a hash which then can be extended without the need to adapt the tex code

- mult-en, mult-de, mult-nl ...

these are generated by mtxrun --script interface --contect

- cont-en.xml cum suis

the derived ones are also generated by the previously mentioned command

- stripped down mult-ini.{mkii,mkiv}

the other two files (mult-con and mult-com) are no longer used

taco and i are currently checking the new zip

Hans



-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | 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 / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Persian interface
       [not found] <6048c4180810271445w4e23a65fj88067d1a9fb66b82@mail.gmail.com>
@ 2008-10-28 21:35 ` Hans Hagen
  0 siblings, 0 replies; 6+ messages in thread
From: Hans Hagen @ 2008-10-28 21:35 UTC (permalink / raw)
  To: Mehdi Omidali, mailing list for ConTeXt users

[-- Attachment #1: Type: text/plain, Size: 763 bytes --]

Mehdi Omidali wrote:

> Attached please find a zipped file containing a sample file and
> mult-def.lua with persian entries added. Other files have been created
> by your method of mtxrun. I couldn't activate persian interface to
> compile the sample file.

i uploaded a beta (you make a persian format with "context --make pe")

the attached file runs ok

Hans


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

[-- Attachment #2: sample.zip --]
[-- Type: application/octet-stream, Size: 430 bytes --]

[-- Attachment #3: Type: text/plain, Size: 487 bytes --]

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

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

end of thread, other threads:[~2008-10-28 21:35 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-10-21 13:24 Persian interface Mehdi Omidali
2008-10-21 14:44 ` Hans Hagen
2008-10-23  4:31   ` Mehdi Omidali
2008-10-23  6:43     ` Wolfgang Schuster
2008-10-23 13:11       ` Hans Hagen
     [not found] <6048c4180810271445w4e23a65fj88067d1a9fb66b82@mail.gmail.com>
2008-10-28 21:35 ` Hans Hagen

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).