Verbose numbers in swedish
Hi, I'm trying to get verbose numbers (i.e. "five" instead of 5) to work when \mainlanguage[sv] is set. I'm new to ConTeXt so I'm still struggling to grasp how everything fits together, but I found the spanish verbose numbers in core-con.lua, and added functions for swedish to match that which seemed relevant. I'm attaching my core-con.lua if that helps. (My additions start at line 1418) My question is, are there more places in other files that also need to be modified for this to work? If so, I would be grateful if you could point me in the right direction. There must be some step that I'm missing. Thank you. MWE where I expect the word "ett" instead of "1": \mainlanguage[sv] \starttext \convertnumber{words}{1} \stoptext
peter kvillegard schrieb am 17.04.2021 um 18:50:
Hi, I'm trying to get verbose numbers (i.e. "five" instead of 5) to work when \mainlanguage[sv] is set. I'm new to ConTeXt so I'm still struggling to grasp how everything fits together, but I found the spanish verbose numbers in core-con.lua, and added functions for swedish to match that which seemed relevant. I'm attaching my core-con.lua if that helps. (My additions start at line 1418)
My question is, are there more places in other files that also need to be modified for this to work? If so, I would be grateful if you could point me in the right direction. There must be some step that I'm missing. Thank you.
MWE where I expect the word "ett" instead of "1": \mainlanguage[sv] \starttext \convertnumber{words}{1} \stoptext
ConTeXt doesn't use the source files itself when you produce a document but uses a format file which contains the content of the source files (which is a lot faster). When you make a change in one of the source files you have to create a new format with includes these changes, to create such a format files type context --make on the command line. Wolfgang
On 4/17/2021 6:50 PM, peter kvillegard wrote:
Hi, I'm trying to get verbose numbers (i.e. "five" instead of 5) to work when \mainlanguage[sv] is set. I'm new to ConTeXt so I'm still struggling to grasp how everything fits together, but I found the spanish verbose numbers in core-con.lua, and added functions for swedish to match that which seemed relevant. I'm attaching my core-con.lua if that helps. (My additions start at line 1418)
My question is, are there more places in other files that also need to be modified for this to work? If so, I would be grateful if you could point me in the right direction. There must be some step that I'm missing. Thank you.
MWE where I expect the word "ett" instead of "1": \mainlanguage[sv] \starttext \convertnumber{words}{1} \stoptext You have to remake the format:
context --make (I'll check the code and add it to the distribution later). 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 -----------------------------------------------------------------
Aha! Thank you so much!
On Sat, Apr 17, 2021 at 7:17 PM Hans Hagen
On 4/17/2021 6:50 PM, peter kvillegard wrote:
Hi, I'm trying to get verbose numbers (i.e. "five" instead of 5) to work when \mainlanguage[sv] is set. I'm new to ConTeXt so I'm still struggling to grasp how everything fits together, but I found the spanish verbose numbers in core-con.lua, and added functions for swedish to match that which seemed relevant. I'm attaching my core-con.lua if that helps. (My additions start at line 1418)
My question is, are there more places in other files that also need to be modified for this to work? If so, I would be grateful if you could point me in the right direction. There must be some step that I'm missing. Thank you.
MWE where I expect the word "ett" instead of "1": \mainlanguage[sv] \starttext \convertnumber{words}{1} \stoptext You have to remake the format:
context --make
(I'll check the code and add it to the distribution later).
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 -----------------------------------------------------------------
participants (3)
-
Hans Hagen
-
peter kvillegard
-
Wolfgang Schuster