Re: Flex-insets in Math mode

2011-11-04 Thread Murat Yildizoglu
Thanks Liviu,
I have now consulted the bug you signal. It seems to be the same problem
indeed.
It would be very nice if we could develop insets also usable in the math
mode.

Murat

2011/11/3 Liviu Andronic landronim...@gmail.com

 7181




-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

h http://myildi.e-jemed.org/ttp://yildizoglu.info

http://www.twitter.com/yildizoglu


Re: Flex-insets in Math mode

2011-11-04 Thread Murat Yildizoglu
Concerning the bug, Julien proposes the following trick:



   - *julien.ri...@gmail.com* added

As a workaround you could have a fake math macro at the top of your
document.

Insert a math macro for \Sexpr{} and put a % in ERT in front of it. Now
you can use \Sexpr in math.
I have tried to follow it, math macros are part of the mysteries of LyX
that I have never used yet, so it is again a first time. I have read the
help document about the macros in the Math manual (but again, even if I
understand the general principle of the macros, I do not understand their
intricacies) and tried to put a macro that generates the following
instruction in the preamble:

\global\long\def\sagecommand#1{\sage\{#1\}}

(I cannot copy and paste the macro definition...)

But when I put \sagecommand{a-Sage-command} in a displayed equation, i get
??a-Sage-command in the math box, as well as in the compiled pdf... instead
of \sage{a-Sage-command} in the final Latex and the results of the Sage
computation in the PDF.

I am pretty sure that I am doing something stupid...

Moreover, the math-macro seems to have crashed other Sage computations that
results from the sagecommand insets (they generate \sage{} commands in the
latex file) that were working before the introduction of the macro.


Murat

2011/11/3 Liviu Andronic landronim...@gmail.com

 On Thu, Nov 3, 2011 at 5:31 PM, Murat Yildizoglu myi...@gmail.com wrote:
  Hello,
  I have waited a little bit before harassing you again with my Sage
 extension
  problem.
  Concerning the possibility of including Sage commands in the math mode, I
  have not found any solution.
 
 I think you're seeing bug #7181.

 Liviu


  Is there a Flex-inset type that can be inserted in a math box, without
 being
  interpreted before the compilation of the document by
  pdflatex+Sage+pdflatex? When I insert my \sage{} instruction in a math
  expression, Lyx tries to interpret what is inside, even if I have set the
  inset as Passtrough=1.
  I know that I can do it using an ERT but I will have to type the complete
  expression in the ERt too in this case :-(  (well, I know that I could
 type
  it in a math box and then copy and paste in the ERT, but I cannot use the
  conveniences of Lyx for displayed equations and equation sets even in
 this
  case).
 
  --
  Prof. Murat Yildizoglu
  Université Montesquieu Bordeaux IV
  GREThA (UMR CNRS 5113)
  Avenue Léon Duguit
  33608 Pessac cedex
  France
 
  yi...@u-bordeaux4.fr
  http://yildizoglu.info
  http://www.twitter.com/yildizoglu
 



 --
 Do you know how to read?
 http://www.alienetworks.com/srtest.cfm
 http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader
 Do you know how to write?
 http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail




-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

h http://myildi.e-jemed.org/ttp://yildizoglu.info

http://www.twitter.com/yildizoglu


Re: Flex-insets in Math mode

2011-11-04 Thread Murat Yildizoglu
Thanks Liviu,
I have now consulted the bug you signal. It seems to be the same problem
indeed.
It would be very nice if we could develop insets also usable in the math
mode.

Murat

2011/11/3 Liviu Andronic landronim...@gmail.com

 7181




-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

h http://myildi.e-jemed.org/ttp://yildizoglu.info

http://www.twitter.com/yildizoglu


Re: Flex-insets in Math mode

2011-11-04 Thread Murat Yildizoglu
Concerning the bug, Julien proposes the following trick:



   - *julien.ri...@gmail.com* added

As a workaround you could have a fake math macro at the top of your
document.

Insert a math macro for \Sexpr{} and put a % in ERT in front of it. Now
you can use \Sexpr in math.
I have tried to follow it, math macros are part of the mysteries of LyX
that I have never used yet, so it is again a first time. I have read the
help document about the macros in the Math manual (but again, even if I
understand the general principle of the macros, I do not understand their
intricacies) and tried to put a macro that generates the following
instruction in the preamble:

\global\long\def\sagecommand#1{\sage\{#1\}}

(I cannot copy and paste the macro definition...)

But when I put \sagecommand{a-Sage-command} in a displayed equation, i get
??a-Sage-command in the math box, as well as in the compiled pdf... instead
of \sage{a-Sage-command} in the final Latex and the results of the Sage
computation in the PDF.

I am pretty sure that I am doing something stupid...

Moreover, the math-macro seems to have crashed other Sage computations that
results from the sagecommand insets (they generate \sage{} commands in the
latex file) that were working before the introduction of the macro.


Murat

2011/11/3 Liviu Andronic landronim...@gmail.com

 On Thu, Nov 3, 2011 at 5:31 PM, Murat Yildizoglu myi...@gmail.com wrote:
  Hello,
  I have waited a little bit before harassing you again with my Sage
 extension
  problem.
  Concerning the possibility of including Sage commands in the math mode, I
  have not found any solution.
 
 I think you're seeing bug #7181.

 Liviu


  Is there a Flex-inset type that can be inserted in a math box, without
 being
  interpreted before the compilation of the document by
  pdflatex+Sage+pdflatex? When I insert my \sage{} instruction in a math
  expression, Lyx tries to interpret what is inside, even if I have set the
  inset as Passtrough=1.
  I know that I can do it using an ERT but I will have to type the complete
  expression in the ERt too in this case :-(  (well, I know that I could
 type
  it in a math box and then copy and paste in the ERT, but I cannot use the
  conveniences of Lyx for displayed equations and equation sets even in
 this
  case).
 
  --
  Prof. Murat Yildizoglu
  Université Montesquieu Bordeaux IV
  GREThA (UMR CNRS 5113)
  Avenue Léon Duguit
  33608 Pessac cedex
  France
 
  yi...@u-bordeaux4.fr
  http://yildizoglu.info
  http://www.twitter.com/yildizoglu
 



 --
 Do you know how to read?
 http://www.alienetworks.com/srtest.cfm
 http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader
 Do you know how to write?
 http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail




-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

h http://myildi.e-jemed.org/ttp://yildizoglu.info

http://www.twitter.com/yildizoglu


Re: Flex-insets in Math mode

2011-11-04 Thread Murat Yildizoglu
Thanks Liviu,
I have now consulted the bug you signal. It seems to be the same problem
indeed.
It would be very nice if we could develop insets also usable in the math
mode.

Murat

2011/11/3 Liviu Andronic 

> 7181




-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

h ttp://yildizoglu.info

http://www.twitter.com/yildizoglu


Re: Flex-insets in Math mode

2011-11-04 Thread Murat Yildizoglu
Concerning the bug, Julien proposes the following trick:

"

   - *julien.ri...@gmail.com* added

As a workaround you could have a "fake" math macro at the top of your
document.

Insert a math macro for \Sexpr{} and put a "%" in ERT in front of it. Now
you can use \Sexpr in math."
I have tried to follow it, math macros are part of the mysteries of LyX
that I have never used yet, so it is again a first time. I have read the
help document about the macros in the Math manual (but again, even if I
understand the general principle of the macros, I do not understand their
intricacies) and tried to put a macro that generates the following
instruction in the preamble:

\global\long\def\sagecommand#1{\sage\{#1\}}

(I cannot copy and paste the macro definition...)

But when I put \sagecommand{a-Sage-command} in a displayed equation, i get
??a-Sage-command in the math box, as well as in the compiled pdf... instead
of \sage{a-Sage-command} in the final Latex and the results of the Sage
computation in the PDF.

I am pretty sure that I am doing something stupid...

Moreover, the math-macro seems to have crashed other Sage computations that
results from the sagecommand insets (they generate \sage{} commands in the
latex file) that were working before the introduction of the macro.


Murat

2011/11/3 Liviu Andronic 

> On Thu, Nov 3, 2011 at 5:31 PM, Murat Yildizoglu  wrote:
> > Hello,
> > I have waited a little bit before harassing you again with my Sage
> extension
> > problem.
> > Concerning the possibility of including Sage commands in the math mode, I
> > have not found any solution.
> >
> I think you're seeing bug #7181.
>
> Liviu
>
>
> > Is there a Flex-inset type that can be inserted in a math box, without
> being
> > interpreted before the compilation of the document by
> > pdflatex+Sage+pdflatex? When I insert my \sage{} instruction in a math
> > expression, Lyx tries to interpret what is inside, even if I have set the
> > inset as Passtrough=1.
> > I know that I can do it using an ERT but I will have to type the complete
> > expression in the ERt too in this case :-(  (well, I know that I could
> type
> > it in a math box and then copy and paste in the ERT, but I cannot use the
> > conveniences of Lyx for displayed equations and equation sets even in
> this
> > case).
> >
> > --
> > Prof. Murat Yildizoglu
> > Université Montesquieu Bordeaux IV
> > GREThA (UMR CNRS 5113)
> > Avenue Léon Duguit
> > 33608 Pessac cedex
> > France
> >
> > yi...@u-bordeaux4.fr
> > http://yildizoglu.info
> > http://www.twitter.com/yildizoglu
> >
>
>
>
> --
> Do you know how to read?
> http://www.alienetworks.com/srtest.cfm
> http://goodies.xfce.org/projects/applications/xfce4-dict#speed-reader
> Do you know how to write?
> http://garbl.home.comcast.net/~garbl/stylemanual/e.htm#e-mail
>



-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

h ttp://yildizoglu.info

http://www.twitter.com/yildizoglu


Flex-insets in Math mode

2011-11-03 Thread Murat Yildizoglu
Hello,

I have waited a little bit before harassing you again with my Sage
extension problem.

Concerning the possibility of including Sage commands in the math mode, I
have not found any solution.

Is there a Flex-inset type that can be inserted in a math box, without
being interpreted before the compilation of the document by
pdflatex+Sage+pdflatex? When I insert my \sage{} instruction in a math
expression, Lyx tries to interpret what is inside, even if I have set the
inset as Passtrough=1.

I know that I can do it using an ERT but I will have to type the complete
expression in the ERt too in this case :-(  (well, I know that I could type
it in a math box and then copy and paste in the ERT, but I cannot use the
conveniences of Lyx for displayed equations and equation sets even in this
case).

-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

http://yildizoglu.info

http://www.twitter.com/yildizoglu


Flex-insets in Math mode

2011-11-03 Thread Murat Yildizoglu
Hello,

I have waited a little bit before harassing you again with my Sage
extension problem.

Concerning the possibility of including Sage commands in the math mode, I
have not found any solution.

Is there a Flex-inset type that can be inserted in a math box, without
being interpreted before the compilation of the document by
pdflatex+Sage+pdflatex? When I insert my \sage{} instruction in a math
expression, Lyx tries to interpret what is inside, even if I have set the
inset as Passtrough=1.

I know that I can do it using an ERT but I will have to type the complete
expression in the ERt too in this case :-(  (well, I know that I could type
it in a math box and then copy and paste in the ERT, but I cannot use the
conveniences of Lyx for displayed equations and equation sets even in this
case).

-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

http://yildizoglu.info

http://www.twitter.com/yildizoglu


Flex-insets in Math mode

2011-11-03 Thread Murat Yildizoglu
Hello,

I have waited a little bit before harassing you again with my Sage
extension problem.

Concerning the possibility of including Sage commands in the math mode, I
have not found any solution.

Is there a Flex-inset type that can be inserted in a math box, without
being interpreted before the compilation of the document by
pdflatex+Sage+pdflatex? When I insert my \sage{} instruction in a math
expression, Lyx tries to interpret what is inside, even if I have set the
inset as Passtrough=1.

I know that I can do it using an ERT but I will have to type the complete
expression in the ERt too in this case :-(  (well, I know that I could type
it in a math box and then copy and paste in the ERT, but I cannot use the
conveniences of Lyx for displayed equations and equation sets even in this
case).

-- 
Prof. Murat Yildizoglu

Université Montesquieu Bordeaux IV
GREThA (UMR CNRS 5113)
Avenue Léon Duguit
33608 Pessac cedex
France

yi...@u-bordeaux4.fr

http://yildizoglu.info

http://www.twitter.com/yildizoglu


Re: Flex insets

2008-11-25 Thread Abdelrazak Younes

rgheck wrote:
You can define shortcuts for them if you like, or even arrange for it to 
be on your menu. What it would do is insert an InsetInfo object into 
your file, which is used e.g. to show which shortcut is associated with 
font-emph. InsetInfo isn't on the menu because it was never intended 
for ordinary users. I'm not sure why you'd want to use it, unless you're 
writing docs for LyX.


Well, the document type is quite useful to the end user. And I reckon 
that once we add some more features (date, etc), this inset could reveal 
very useful.


Abdel.



Re: Flex insets

2008-11-25 Thread Abdelrazak Younes

rgheck wrote:
You can define shortcuts for them if you like, or even arrange for it to 
be on your menu. What it would do is insert an InsetInfo object into 
your file, which is used e.g. to show which shortcut is associated with 
font-emph. InsetInfo isn't on the menu because it was never intended 
for ordinary users. I'm not sure why you'd want to use it, unless you're 
writing docs for LyX.


Well, the document type is quite useful to the end user. And I reckon 
that once we add some more features (date, etc), this inset could reveal 
very useful.


Abdel.



Re: Flex insets

2008-11-25 Thread Abdelrazak Younes

rgheck wrote:
You can define shortcuts for them if you like, or even arrange for it to 
be on your menu. What it would do is insert an InsetInfo object into 
your file, which is used e.g. to show which shortcut is associated with 
"font-emph". InsetInfo isn't on the menu because it was never intended 
for ordinary users. I'm not sure why you'd want to use it, unless you're 
writing docs for LyX.


Well, the document type is quite useful to the end user. And I reckon 
that once we add some more features (date, etc), this inset could reveal 
very useful.


Abdel.



Flex insets

2008-11-24 Thread Max Bian
In layout directory stdinsets.inc, there are definitions of 
Info:menu, Info:shortcut, and Info:shortcuts. It appears that these are 
the ones to define the menu/shortcut styles in the help files. However, 
I don't see there is anyway to use these from LyX menu. Actually, the 
definitions in Logical Markup module is listed in Edit-Text Style.


I am a little confused. Shouldn't these Info:??? styles be available 
from the LyX Menu, like Algorithm, Box, ERT, etc? Or am I only supposed 
to copy them and make my own in a layout or module file?


I am using lyx 1.6 on Windows.

Thanks.

Max


Re: Flex insets

2008-11-24 Thread rgheck

Max Bian wrote:
In layout directory stdinsets.inc, there are definitions of 
Info:menu, Info:shortcut, and Info:shortcuts. It appears that these 
are the ones to define the menu/shortcut styles in the help files. 
However, I don't see there is anyway to use these from LyX menu. 
Actually, the definitions in Logical Markup module is listed in 
Edit-Text Style.


I am a little confused. Shouldn't these Info:??? styles be available 
from the LyX Menu, like Algorithm, Box, ERT, etc? Or am I only 
supposed to copy them and make my own in a layout or module file?


I am using lyx 1.6 on Windows.

You can define shortcuts for them if you like, or even arrange for it to 
be on your menu. What it would do is insert an InsetInfo object into 
your file, which is used e.g. to show which shortcut is associated with 
font-emph. InsetInfo isn't on the menu because it was never intended 
for ordinary users. I'm not sure why you'd want to use it, unless you're 
writing docs for LyX.


rh



Re: Flex insets

2008-11-24 Thread Jean-Marc Lasgouttes
I am a little confused. Shouldn't these Info:??? styles be  
available from the LyX Menu, like Algorithm, Box, ERT, etc? Or am  
I only supposed to copy them and make my own in a layout or module  
file?
You can define shortcuts for them if you like, or even arrange for  
it to be on your menu.


FWIW the shortcut is already Ctrl-Shift-I.

JMarc


Flex insets

2008-11-24 Thread Max Bian
In layout directory stdinsets.inc, there are definitions of 
Info:menu, Info:shortcut, and Info:shortcuts. It appears that these are 
the ones to define the menu/shortcut styles in the help files. However, 
I don't see there is anyway to use these from LyX menu. Actually, the 
definitions in Logical Markup module is listed in Edit-Text Style.


I am a little confused. Shouldn't these Info:??? styles be available 
from the LyX Menu, like Algorithm, Box, ERT, etc? Or am I only supposed 
to copy them and make my own in a layout or module file?


I am using lyx 1.6 on Windows.

Thanks.

Max


Re: Flex insets

2008-11-24 Thread rgheck

Max Bian wrote:
In layout directory stdinsets.inc, there are definitions of 
Info:menu, Info:shortcut, and Info:shortcuts. It appears that these 
are the ones to define the menu/shortcut styles in the help files. 
However, I don't see there is anyway to use these from LyX menu. 
Actually, the definitions in Logical Markup module is listed in 
Edit-Text Style.


I am a little confused. Shouldn't these Info:??? styles be available 
from the LyX Menu, like Algorithm, Box, ERT, etc? Or am I only 
supposed to copy them and make my own in a layout or module file?


I am using lyx 1.6 on Windows.

You can define shortcuts for them if you like, or even arrange for it to 
be on your menu. What it would do is insert an InsetInfo object into 
your file, which is used e.g. to show which shortcut is associated with 
font-emph. InsetInfo isn't on the menu because it was never intended 
for ordinary users. I'm not sure why you'd want to use it, unless you're 
writing docs for LyX.


rh



Re: Flex insets

2008-11-24 Thread Jean-Marc Lasgouttes
I am a little confused. Shouldn't these Info:??? styles be  
available from the LyX Menu, like Algorithm, Box, ERT, etc? Or am  
I only supposed to copy them and make my own in a layout or module  
file?
You can define shortcuts for them if you like, or even arrange for  
it to be on your menu.


FWIW the shortcut is already Ctrl-Shift-I.

JMarc


Flex insets

2008-11-24 Thread Max Bian
In layout directory "stdinsets.inc", there are definitions of 
Info:menu, Info:shortcut, and Info:shortcuts. It appears that these are 
the ones to define the menu/shortcut styles in the help files. However, 
I don't see there is anyway to use these from LyX menu. Actually, the 
definitions in Logical Markup module is listed in Edit->Text Style.


I am a little confused. Shouldn't these "Info:???" styles be available 
from the LyX Menu, like Algorithm, Box, ERT, etc? Or am I only supposed 
to copy them and make my own in a layout or module file?


I am using lyx 1.6 on Windows.

Thanks.

Max


Re: Flex insets

2008-11-24 Thread rgheck

Max Bian wrote:
In layout directory "stdinsets.inc", there are definitions of 
Info:menu, Info:shortcut, and Info:shortcuts. It appears that these 
are the ones to define the menu/shortcut styles in the help files. 
However, I don't see there is anyway to use these from LyX menu. 
Actually, the definitions in Logical Markup module is listed in 
Edit->Text Style.


I am a little confused. Shouldn't these "Info:???" styles be available 
from the LyX Menu, like Algorithm, Box, ERT, etc? Or am I only 
supposed to copy them and make my own in a layout or module file?


I am using lyx 1.6 on Windows.

You can define shortcuts for them if you like, or even arrange for it to 
be on your menu. What it would do is insert an InsetInfo object into 
your file, which is used e.g. to show which shortcut is associated with 
"font-emph". InsetInfo isn't on the menu because it was never intended 
for ordinary users. I'm not sure why you'd want to use it, unless you're 
writing docs for LyX.


rh



Re: Flex insets

2008-11-24 Thread Jean-Marc Lasgouttes
I am a little confused. Shouldn't these "Info:???" styles be  
available from the LyX Menu, like Algorithm, Box, ERT, etc? Or am  
I only supposed to copy them and make my own in a layout or module  
file?
You can define shortcuts for them if you like, or even arrange for  
it to be on your menu.


FWIW the shortcut is already Ctrl-Shift-I.

JMarc