Hello list,
I'd like to place the text "DRAFT" in the left and right side margins of every page, rotated 90 degrees so that the text runs vertically. It would be nice if the text was 180 degrees rotated on the right side in comparison to the left margin. I've tried with overlays and I can't seem to get them to work correctly.
This should be simple, but as with so many things with ConTeXt it's a bit enigmatic.
Am 03.06.24 um 02:45 schrieb Kip Warner:
Hello list,
I'd like to place the text "DRAFT" in the left and right side margins of every page, rotated 90 degrees so that the text runs vertically. It would be nice if the text was 180 degrees rotated on the right side in comparison to the left margin. I've tried with overlays and I can't seem to get them to work correctly.
This should be simple, but as with so many things with ConTeXt it's a bit enigmatic.
* repeated layers * \rotate
Please make a M(n)WE that we can enhance.
Hraban
you can try 'setuptext' and '\setuptexttexts' to put "draft" in margin.and use 'orientation' to change direction.
%%%% \defineframed [marginframe] [width=max, height=max, style=\ss, corner=08, location=lohi, frame=off] \setuptext [style={\ss}] \setuptexttexts [margin] [] [\marginframe{\hbox orientation 1 {DRAFT}}] [\marginframe{\hbox orientation 1 {DRAFT}}] []
\starttext \chapter{C:Some Word} \dorecurse{5}{ \section{S:Some Word} \input knuth} \stoptext %%%
ai2472206007@yeah.net schrieb am 03.06.2024 um 11:35:
you can try 'setuptext' and '\setuptexttexts' to put "draft" in margin.and use 'orientation' to change direction.
%%%% \defineframed [marginframe] [width=max, height=max, style=\ss, corner=08, location=lohi, frame=off] \setuptext [style={\ss}] \setuptexttexts [margin] [] [\marginframe{\hbox orientation 1 {DRAFT}}] [\marginframe{\hbox orientation 1 {DRAFT}}]
There is no need for low level option when you use \rotate, e.g.
[\marginframe{\rotate[rotation=270]{DRAFT}}]
\framed has a orientation key but it's not so easy to use in this case because you have to set length for width and height, e.g.
\defineframed [marginframe] [width=\textheight, height=\rightmarginwidth, orientation=270]
Wolfgang
On Mon, 2024-06-03 at 17:04 +0200, Wolfgang Schuster wrote:
ai2472206007@yeah.net schrieb am 03.06.2024 um 11:35:
you can try 'setuptext' and '\setuptexttexts' to put "draft" in margin.and use 'orientation' to change direction.
%%%% \defineframed [marginframe] [width=max, height=max, style=\ss, corner=08, location=lohi, frame=off] \setuptext [style={\ss}] \setuptexttexts [margin] [] [\marginframe{\hbox orientation 1 {DRAFT}}] [\marginframe{\hbox orientation 1 {DRAFT}}]
There is no need for low level option when you use \rotate, e.g.
[\marginframe{\rotate[rotation=270]{DRAFT}}]
\framed has a orientation key but it's not so easy to use in this case because you have to set length for width and height, e.g.
\defineframed [marginframe] [width=\textheight, height=\rightmarginwidth, orientation=270]
Wolfgang
Thank you kindly, Wolfgang et al. Very helpful.
Hello Wolfgang,
I've been using your letter module for many years, but I noticed since upgrading to ConTeXt 2024.06.21 23:32 it seems to have stopped working.
I tried your sample here:
https://wiki.contextgarden.net/Letter#Hraban.E2.80.99s_complicated_logo_and_...
When I try to typeset it, I see the following:
$ context minimal.tex
resolvers | formats | executing runner 'run luametatex format': /home/kip/.local/non-fhs/context/tex/texmf-linux-64/bin/luametatex --jobname="./minimal.tex" --socket --shell-escape --fmt=/home/kip/.local/non-fhs/context/tex/texmf-cache/luametatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.fmt --lua=/home/kip/.local/non-fhs/context/tex/texmf-cache/luametatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.lui --c:currentrun=1 --c:fulljobname="./minimal.tex" --c:input="./minimal.tex" --c:kindofrun=1 --c:maxnofruns=9 --c:texmfbinpath="/home/kip/.local/non-fhs/context/tex/texmf-linux-64/bin" system > system > ConTeXt ver: 2024.06.21 23:32 LMTX fmt: 2024.6.21 int: english/english system > system > 'cont-new.mkxl' loaded open source > level 1, order 1, name '/home/kip/.local/non-fhs/context/tex/texmf-context/tex/context/base/mkxl/cont-new.mkxl' system > beware: some patches loaded from cont-new.mkiv close source > level 1, order 1, name '/home/kip/.local/non-fhs/context/tex/texmf-context/tex/context/base/mkxl/cont-new.mkxl' system > files > jobname './minimal', input './minimal.tex', result './minimal' fonts > latin modern fonts are not preloaded languages > language 'en' is active open source > level 1, order 2, name './minimal.tex' modules > 'letter' is not found fonts > preloading latin modern fonts (third stage) fonts > 'fallback modern rm 10pt' is loaded tex error > tex error on line 10 in file ./minimal.tex: Undefined control sequence
<line 3.10> \setupletteroptions
1 \mainlanguage[nl] 2 \usemodule[letter] 3 4 \setuplanguage [nl] [date={year, –, mm, –, dd}] % ISO 8601 date 5 6 \setupbodyfont [rm, 10pt] 7 \setupinterlinespace[3.0ex] % default: 2.8ex 8 \setbreakpoints[compound] % break at / and - 9 10 >> \setupletteroptions 11 [language=netherlands, 12 bodyfont={rm,10pt}, 13 whitespace=1.5ex, %3ex 14 ] 15 16 \setuptabulate[distance=0pt] 17 18 \setupletter[ 19 % Sender address in envelope window 20 backaddress={Pragma ADE · H.,Hagen · Riderstraat 27 · NL-8061 GH Hasselt} The control sequence at the end of the top line of your error message was never \def'ed. You can just continue as I'll forget about whatever was undefined.
Is the letter module no longer supported? If so, how do users transition from \setuplettertext, \setuplettersection, \setupletterlayer, \setupletterframe, \setupletteroptions, \setupletter, and \setupletterdescription?
Am 26.06.24 um 02:12 schrieb Kip Warner:
Hello Wolfgang,
I've been using your letter module for many years, but I noticed since upgrading to ConTeXt 2024.06.21 23:32 it seems to have stopped working.
I tried your sample here:
https://wiki.contextgarden.net/Letter#Hraban.E2.80.99s_complicated_logo_and_address_setup
Hi Kip, as the title says it’s my sample.
I’ve no problems with the module in LMTX 2024.06.18 or 2024.06.21, neither with my usual letters nor with the example.
Usually, there should be some log lines that tell you about the loading of the module:
modules > 'letter' is loaded open source > level 2, order 3, name '/Users/hraban/context/tex/texmf-modules/tex/context/third/letter/base/s-cor-01.mkvi'
Please check if the module is there and re-generate the file database.
Hraban
On Wed, 2024-06-26 at 08:31 +0200, Henning Hraban Ramm wrote:
Hey Henning,
I’ve no problems with the module in LMTX 2024.06.18 or 2024.06.21, neither with my usual letters nor with the example.
Usually, there should be some log lines that tell you about the loading of the module:
modules > 'letter' is loaded open source > level 2, order 3, name '/Users/hraban/context/tex/texmf- modules/tex/context/third/letter/base/s-cor-01.mkvi'
Please check if the module is there and re-generate the file database.
It looks like it is not. I followed these instructions for installation of ConTeXt on a 64-bit GNU/Linux system:
https://wiki.contextgarden.net/Installation#GNU.2FLinux_2
I notice that the context/tex/texmf-modules directory exists, but there is nothing in it, after the installation completes. Is there an argument that needs to be passed to ./install.sh perhaps?
Kip Warner schrieb am 26.06.2024 um 21:08:
On Wed, 2024-06-26 at 08:31 +0200, Henning Hraban Ramm wrote:
Hey Henning,
I’ve no problems with the module in LMTX 2024.06.18 or 2024.06.21, neither with my usual letters nor with the example.
Usually, there should be some log lines that tell you about the loading of the module:
modules > 'letter' is loaded open source > level 2, order 3, name '/Users/hraban/context/tex/texmf- modules/tex/context/third/letter/base/s-cor-01.mkvi'
Please check if the module is there and re-generate the file database.
It looks like it is not. I followed these instructions for installation of ConTeXt on a 64-bit GNU/Linux system:
https://wiki.contextgarden.net/Installation#GNU.2FLinux_2
I notice that the context/tex/texmf-modules directory exists, but there is nothing in it, after the installation completes. Is there an argument that needs to be passed to ./install.sh perhaps?
https://wiki.contextgarden.net/Modules#Installation_by_script_.28LMTX.29
Wolfgang
On Wed, 2024-06-26 at 21:17 +0200, Wolfgang Schuster wrote:
https://wiki.contextgarden.net/Modules#Installation_by_script_.28LMTX.29
Thank you greatly, Wolfgang. That worked!
Will the modules automatically update when I run ./install.sh, or do I need to periodically run the following?
$ mtxrun --script install-modules --install --all
On 6/26/24 21:33, Kip Warner wrote:
[...] Will the modules automatically update when I run ./install.sh, or do I need to periodically run the following?
$ mtxrun --script install-modules --install --all
Hi Kip,
you need the second option.
Cheers,
Pablo
On Wed, 2024-06-26 at 21:46 +0200, Pablo Rodriguez wrote:
Hi Kip,
you need the second option.
Cheers,
Thanks Pablo. I wonder if it might be helpful if the modules were installed by default since they're not that numerous or large in size?