Re: InsetText question

2004-11-07 Thread Andre Poenitz
On Wed, Nov 03, 2004 at 12:53:42PM +0100, Jean-Marc Lasgouttes wrote: > > "Juergen" == Juergen Spitzmueller <[EMAIL PROTECTED]> writes: > > Juergen> Is it possible to check from within a text inset whether the > Juergen> cursor is inside that given inset? I have tried cur.inset() > Juergen> an

Re: InsetText question

2004-11-03 Thread Jean-Marc Lasgouttes
> "Juergen" == Juergen Spitzmueller <[EMAIL PROTECTED]> writes: Juergen> Is it possible to check from within a text inset whether the Juergen> cursor is inside that given inset? I have tried cur.inset() Juergen> and failed. Basically, I want to draw a visual clue when the Juergen> cursor is in

Re: InsetText question

2004-11-02 Thread Juergen Spitzmueller
Andre Poenitz wrote: > Use LCursor::isInside(InsetBase *) Thanks, I try this when I'm back home (actually, I thought that this function is still bound to mathed). Jürgen

Re: InsetText question

2004-11-01 Thread Andre Poenitz
On Mon, Nov 01, 2004 at 12:55:52PM +0100, Juergen Spitzmueller wrote: > Is it possible to check from within a text inset whether the cursor is > inside that given inset? I have tried cur.inset() and failed. > Basically, I want to draw a visual clue when the cursor is inside a > char style inset (ju

InsetText question

2004-11-01 Thread Juergen Spitzmueller
Is it possible to check from within a text inset whether the cursor is inside that given inset? I have tried cur.inset() and failed. Basically, I want to draw a visual clue when the cursor is inside a char style inset (just like mathed's inline insets do). Thanks, Jürgen

Re: insettext question

2003-08-27 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 06:52:45PM +0200, Juergen Spitzmueller wrote: > Andre Poenitz wrote: > > \begin{tabular}{|p{6cm}|} > > \hline > > \centering par1\tabularnewline > > par2\tabularnewline > > \hline > > \end{tabular} > > > > looks identical to the last one and has 'centering' for centered > >

Re: insettext question

2003-08-26 Thread Juergen Spitzmueller
Andre Poenitz wrote: > \begin{tabular}{|p{6cm}|} > \hline > \centering par1\tabularnewline > par2\tabularnewline > \hline > \end{tabular} > > looks identical to the last one and has 'centering' for centered > paragraphs and nothing for 'normal' once. Indeed. This is certainly the simplest solution

Re: insettext question

2003-08-26 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 04:06:53PM +0200, Juergen Spitzmueller wrote: > Am Dienstag, 26. August 2003 15:53 schrieb Andre Poenitz: > > Ok, you lost me. > > > > THis works, so what's wrong with using \centering all over the place? > > Maybe I am completely wrong, but compare > > \begin{tabular}{|p{

Re: insettext question

2003-08-26 Thread Juergen Spitzmueller
Am Dienstag, 26. August 2003 15:53 schrieb Andre Poenitz: > Ok, you lost me. > > THis works, so what's wrong with using \centering all over the place? Maybe I am completely wrong, but compare \begin{tabular}{|p{6cm}|} \hline {\centering par1\par}\tabularnewline \hline \end{tabular} to \begin{ta

Re: insettext question

2003-08-26 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 03:50:49PM +0200, Juergen Spitzmueller wrote: > Andre Poenitz wrote: > > > consider a cell > > > par1 > > > par2 > > > par3 > > > > How do I create such a thing in TeX/LyX? > > \begin{tabular}{|p{6cm}|} > \hline > {\centering par1\par} > > {\raggedright par2\par} > > par3

Re: insettext question

2003-08-26 Thread Juergen Spitzmueller
Andre Poenitz wrote: > > consider a cell > > par1 > > par2 > > par3 > > How do I create such a thing in TeX/LyX? \begin{tabular}{|p{6cm}|} \hline {\centering par1\par} {\raggedright par2\par} par3\tabularnewline \hline \end{tabular} Juergen

Re: insettext question

2003-08-26 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 03:33:31PM +0200, Juergen Spitzmueller wrote: > I'd rather let LyX use the appropriate command than inserting such stuff into > the document. I think with the solution you and Alfredo pointed out, it > should be possible. As long as you don't start using fancy back pointe

Re: insettext question

2003-08-26 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 03:25:02PM +0200, Juergen Spitzmueller wrote: > Andre Poenitz wrote: > > Can't this be solved by some TeX trickery? > > None that I'm aware of. > > > It's a TeX problem after all... > > Indeed. > > > What's wrong with using \centering in the other cells? > > We can use

Re: insettext question

2003-08-26 Thread Juergen Spitzmueller
Andre Poenitz wrote: > Concerning the TeX trickery: > > \makeatletter > [EMAIL PROTECTED] > \makeatother > > \begin{tabular}{p{3cm}}a\xpar b \xpar c\xpar\end{tabular} > > is certainly not perfect, but seems to work by adding a \par unless > the next token is \end. > > Would that help? I'd rather l

Re: insettext question

2003-08-26 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 03:09:21PM +0200, Juergen Spitzmueller wrote: > Andre Poenitz wrote: > > InsetText::paragraphs().back() is the last par in this text. > > thanks. is this a bool? > > > What exactly do you need? > > I'm trying to get the alignment in floats and table cells right (our curre

Re: insettext question

2003-08-26 Thread Juergen Spitzmueller
Alfredo Braunstein wrote: > No, a reference to the last par in the list if there is one. > (InsetText::paragraphs() is a std::list). If you have a > Paragraph par, you can check for &par == &InsetText::paragraphs().back(). > Better, if you have an iterator pit pointing to your par in the list and >

Re: insettext question

2003-08-26 Thread Juergen Spitzmueller
Andre Poenitz wrote: > Can't this be solved by some TeX trickery? None that I'm aware of. > It's a TeX problem after all... Indeed. > What's wrong with using \centering in the other cells? We can use centering in most cases, but if there are more than one paragraphs, we need a way to switch b

Re: insettext question

2003-08-26 Thread Alfredo Braunstein
Juergen Spitzmueller wrote: > Andre Poenitz wrote: >> InsetText::paragraphs().back() is the last par in this text. > > thanks. is this a bool? No, a reference to the last par in the list if there is one. (InsetText::paragraphs() is a std::list). If you have a Paragraph par, you can check for &pa

Re: insettext question

2003-08-26 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 03:09:21PM +0200, Juergen Spitzmueller wrote: > Andre Poenitz wrote: > > InsetText::paragraphs().back() is the last par in this text. > > thanks. is this a bool? No, a reference to the last par. > I'm trying to get the alignment in floats and table cells right (our curren

Re: insettext question

2003-08-26 Thread Juergen Spitzmueller
Andre Poenitz wrote: > InsetText::paragraphs().back() is the last par in this text. thanks. is this a bool? > What exactly do you need? I'm trying to get the alignment in floats and table cells right (our current \begin{center}...\end{center} inserts unwanted space). http://bugzilla.lyx.org/sh

Re: insettext question

2003-08-26 Thread Andre Poenitz
On Tue, Aug 26, 2003 at 02:49:46PM +0200, Juergen Spitzmueller wrote: > is there a way to check if a paragraph is the very last paragraph in an > insettext? (I'm interested in the last paragraphs of a table cell). InsetText::paragraphs().back() is the last par in this text. What exactly do you n

insettext question

2003-08-26 Thread Juergen Spitzmueller
is there a way to check if a paragraph is the very last paragraph in an insettext? (I'm interested in the last paragraphs of a table cell). Thanks, Juergen.