treat framed and externalfigure as characters
Hello Taco and Hans, in http://context.literatesolutions.com/collector/89 you write "Both Hans and me have documents that depend on \framed staying in vertical mode." Could you give me an example please? Cheers, Peter -- http://pmrb.free.fr/contact/
Peter Münster wrote:
Hello Taco and Hans,
in http://context.literatesolutions.com/collector/89 you write "Both Hans and me have documents that depend on \framed staying in vertical mode."
Could you give me an example please?
For instance in a recipe booklet, where one of the macros goes like this: \def\startrecipe[#1]% {\getparameters[Recipe] [Title=,Summary=,Image=none,#1]% .. \framed{\tfd \RecipeTitle}% \externalfigure[\RecipeImage]% {\bf\RecipeSummary}% \blank } I am not saying that that is the best way to write macros (and I certainly do not do it like that anymore) but changing the behaviour would break quite a lot of my existing documents, including some I have been payed for to do. Maybe Hans is willing to add a global switch that you can set at the top of your document(s). For Hans: Peter would like an implicit \dontleavehmode added to \framed and \externalfigure, so they behave more like characters (not like \hboxes). Cheers, Taco
On Tue, 9 May 2006, Taco Hoekwater wrote:
Peter Münster wrote:
Hello Taco and Hans,
in http://context.literatesolutions.com/collector/89 you write "Both Hans and me have documents that depend on \framed staying in vertical mode."
Could you give me an example please?
For instance in a recipe booklet, where one of the macros goes like this:
\def\startrecipe[#1]% {\getparameters[Recipe] [Title=,Summary=,Image=none,#1]% .. \framed{\tfd \RecipeTitle}% \externalfigure[\RecipeImage]% {\bf\RecipeSummary}% \blank }
I am not saying that that is the best way to write macros (and I certainly do not do it like that anymore) but changing the behaviour would break quite a lot of my existing documents, including some I have been payed for to do.
Hello Taco, I understand and accept your arguments. Even for me, it's no more problem to add here and there a \dontleavehmode, since I know it now. But for a beginner and a user without ambition to become a ConTeXt expert, the actual behaviour is annoying. He just sees a line break, where he does not expect it. There is a fundamental difference between bla \framed{bla} bla and \framed{bla} bla bla that is not understandable. It's much more straightforward and clear to add a \par (and perhaps \noindentation) if you really want this line break (for example in your macro \startrecipe).
Maybe Hans is willing to add a global switch that you can set at the top of your document(s).
Perhaps one day, I would like to convert some of my colleagues from M$-Word to ConTeXt, but if I have to teach them about things like \dontleavehmode there is no need for further efforts. So, such a switch would be very welcome (I would put it into cont-sys.tex)! Cheers, Peter -- http://pmrb.free.fr/contact/
� wrote:
I understand and accept your arguments. Even for me, it's no more problem to add here and there a \dontleavehmode, since I know it now. But for a beginner and a user without ambition to become a ConTeXt expert, the actual behaviour is annoying. He just sees a line break, where he does not expect it. There is a fundamental difference between bla \framed{bla} bla and \framed{bla} bla bla that is not understandable.
this is the case for many more things and a tex speciality which takes while to get accustomed to; a similar case is {\bf whatever} rest of par best put a \dontleavevmode or \strut in front if you want indentation and related features to work
Perhaps one day, I would like to convert some of my colleagues from M$-Word to ConTeXt, but if I have to teach them about things like \dontleavehmode there is no need for further efforts. So, such a switch would be very welcome (I would put it into cont-sys.tex)!
but then it would break other things and your collegues would scream about that btw, there is \inframed for inline usage, or one could define a symbol 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 -----------------------------------------------------------------
On Tue, 9 May 2006, Hans Hagen wrote:
There is a fundamental difference between bla \framed{bla} bla and \framed{bla} bla bla that is not understandable.
this is the case for many more things and a tex speciality which takes while to get accustomed to; a similar case is
{\bf whatever} rest of par
Hello Hans, I tried this: \setupindenting[big,yes] \starttext \input tufte {\bf whatever} rest of par \input tufte \stoptext But I don't see the problem... ?
btw, there is \inframed for inline usage, or one could define a symbol
Thanks, I'll take a look at it. Cheers, Peter -- http://pmrb.free.fr/contact/
� wrote:
On Tue, 9 May 2006, Hans Hagen wrote:
There is a fundamental difference between bla \framed{bla} bla and \framed{bla} bla bla that is not understandable.
this is the case for many more things and a tex speciality which takes while to get accustomed to; a similar case is
{\bf whatever} rest of par
Hello Hans, I tried this: \setupindenting[big,yes] \starttext \input tufte
{\bf whatever} rest of par \input tufte \stoptext
But I don't see the problem... ?
it's just an example (bad one because i don't remember the cases) think of {\command ...} rest of par \command ... rest of par and possible interferences with special \everypar situations (par starts in group or with command that itself does something that depends on the h/v mode) 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 -----------------------------------------------------------------
Taco Hoekwater wrote:
Peter M�nster wrote:
Hello Taco and Hans,
in http://context.literatesolutions.com/collector/89 you write "Both Hans and me have documents that depend on \framed staying in vertical mode."
Could you give me an example please?
For instance in a recipe booklet, where one of the macros goes like this:
\def\startrecipe[#1]% {\getparameters[Recipe] [Title=,Summary=,Image=none,#1]% .. \framed{\tfd \RecipeTitle}% \externalfigure[\RecipeImage]% {\bf\RecipeSummary}% \blank }
I am not saying that that is the best way to write macros (and I certainly do not do it like that anymore) but changing the behaviour would break quite a lot of my existing documents, including some I have been payed for to do.
Maybe Hans is willing to add a global switch that you can set at the top of your document(s).
For Hans: Peter would like an implicit \dontleavehmode added to \framed and \externalfigure, so they behave more like characters (not like \hboxes).
as you say, a dangerous feature that would break much (keep in mind that \framed is used all over the place) 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 -----------------------------------------------------------------
participants (3)
-
Hans Hagen
-
Peter Münster
-
Taco Hoekwater