Re: Toggle comments in Lyx->LaTeX Preamble

2018-02-22 Thread Paul A. Rubin

On 02/22/2018 05:06 PM, Richard Heck wrote:

On 02/22/2018 04:00 PM, Paul A Rubin wrote:




On 02/22/2018 03:37 PM, Richard Heck wrote:

On 02/22/2018 03:05 PM, Joel Kulesza wrote:
On Thu, Feb 22, 2018 at 12:52 PM, Daniel Gómez Martínez 
mailto:dangome...@gmail.com>> wrote:


Hello everyone,

I have large sections of customized TeX code in the LaTeX
preamble of some LyX templates I've created over time. I would
like to know if there's a way to quickly toggle between
commented and uncommented line for a given selection of lines
(say, with a keyboard shortcut)


I don't know of a way to do this.

, and in case there's not a quick way to do this, I would like
to ask the developers if they can include this feature in
Settings->Document->LaTeX Preamble and in the TeX code environment


I would be happy to see this also.

(the one you have with Ctrl+L), it would also be great if a
message of how to do so (toggle comment lines keyboard
shortcut) could be included in the Settings->Document->LaTeX
Preamble sub-window.

I'm sure I've read somewhere that LyX tries to the highest
extent to be so complete that users don't usually have to put
TeX or Preamble code lines, but as we users have some really
customized and variable needs


The approach I use is to write a separate, external, preamble.tex 
file that I then put alongside the .lyx file and in LyX's premable 
I issue "\input{preamble.tex}".  Then, I can (un)comment the 
contained behavior in one line. Naturally, one can use multiple 
preamble files to segregate behaviors.  Using this approach also 
allows multiple documents to share a common preamble.  Further, by 
symbolically linking the .tex file, an update in one instance 
updates behaviors globally.


If one's preamble-related needs have become this sophisticated, then 
I'd recommend this approach. I don't think we really want to 
implement a full-fledged LaTeX editor inside LyX. What might be more 
plausible, and something I think we have considered, is to have some 
way to launch an external text editor and then read back whatever's 
provided, kind of like we do with graphics (say).


We already have line-begin, self-insert and char-delete-forward 
LFUNs. If someone were to add a "for-each-selected-line" LFUN (with a 
shorter name) that would take a command or command-sequence as its 
argument, block comment/uncomment could be done as a macro.


Those don't apply in the case of hte LaTeX preamble. That's just a 
text editing widget provided by Qt.


Richard


Oops. Missed that.

Paul



Re: Toggle comments in Lyx->LaTeX Preamble

2018-02-22 Thread Richard Heck
On 02/22/2018 04:00 PM, Paul A Rubin wrote:
>
>
>
> On 02/22/2018 03:37 PM, Richard Heck wrote:
>> On 02/22/2018 03:05 PM, Joel Kulesza wrote:
>>> On Thu, Feb 22, 2018 at 12:52 PM, Daniel Gómez Martínez
>>> mailto:dangome...@gmail.com>> wrote:
>>>
>>> Hello everyone,
>>>
>>> I have large sections of customized TeX code in the LaTeX
>>> preamble of some LyX templates I've created over time. I would
>>> like to know if there's a way to quickly toggle between
>>> commented and uncommented line for a given selection of lines
>>> (say, with a keyboard shortcut)
>>>
>>>
>>> I don't know of a way to do this.
>>>  
>>>
>>> , and in case there's not a quick way to do this, I would like
>>> to ask the developers if they can include this feature in
>>> Settings->Document->LaTeX Preamble and in the TeX code environment
>>>
>>>
>>> I would be happy to see this also.
>>>  
>>>
>>> (the one you have with Ctrl+L), it would also be great if a
>>> message of how to do so (toggle comment lines keyboard shortcut)
>>> could be included in the Settings->Document->LaTeX Preamble
>>> sub-window.
>>>
>>> I'm sure I've read somewhere that LyX tries to the highest
>>> extent to be so complete that users don't usually have to put
>>> TeX or Preamble code lines, but as we users have some really
>>> customized and variable needs
>>>
>>>
>>> The approach I use is to write a separate, external, preamble.tex
>>> file that I then put alongside the .lyx file and in LyX's premable I
>>> issue "\input{preamble.tex}".  Then, I can (un)comment the contained
>>> behavior in one line.  Naturally, one can use multiple preamble
>>> files to segregate behaviors.  Using this approach also allows
>>> multiple documents to share a common preamble.  Further, by
>>> symbolically linking the .tex file, an update in one instance
>>> updates behaviors globally.
>>
>> If one's preamble-related needs have become this sophisticated, then
>> I'd recommend this approach. I don't think we really want to
>> implement a full-fledged LaTeX editor inside LyX. What might be more
>> plausible, and something I think we have considered, is to have some
>> way to launch an external text editor and then read back whatever's
>> provided, kind of like we do with graphics (say).
>
> We already have line-begin, self-insert and char-delete-forward LFUNs.
> If someone were to add a "for-each-selected-line" LFUN (with a shorter
> name) that would take a command or command-sequence as its argument,
> block comment/uncomment could be done as a macro.

Those don't apply in the case of hte LaTeX preamble. That's just a text
editing widget provided by Qt.

Richard



Re: Toggle comments in Lyx->LaTeX Preamble

2018-02-22 Thread Scott Kostyshak
On Thu, Feb 22, 2018 at 08:37:44PM +, Richard Heck wrote:

> What might be more plausible, and
> something I think we have considered, is to have some way to launch an
> external text editor and then read back whatever's provided, kind of
> like we do with graphics (say).

There is a trac ticket for this somewhere.

Scott


signature.asc
Description: PGP signature


Re: Toggle comments in Lyx->LaTeX Preamble

2018-02-22 Thread Paul A Rubin



On 02/22/2018 03:37 PM, Richard Heck wrote:

On 02/22/2018 03:05 PM, Joel Kulesza wrote:
On Thu, Feb 22, 2018 at 12:52 PM, Daniel Gómez Martínez 
mailto:dangome...@gmail.com>> wrote:


Hello everyone,

I have large sections of customized TeX code in the LaTeX
preamble of some LyX templates I've created over time. I would
like to know if there's a way to quickly toggle between commented
and uncommented line for a given selection of lines (say, with a
keyboard shortcut)


I don't know of a way to do this.

, and in case there's not a quick way to do this, I would like to
ask the developers if they can include this feature in
Settings->Document->LaTeX Preamble and in the TeX code environment


I would be happy to see this also.

(the one you have with Ctrl+L), it would also be great if a
message of how to do so (toggle comment lines keyboard shortcut)
could be included in the Settings->Document->LaTeX Preamble
sub-window.

I'm sure I've read somewhere that LyX tries to the highest extent
to be so complete that users don't usually have to put TeX or
Preamble code lines, but as we users have some really customized
and variable needs


The approach I use is to write a separate, external, preamble.tex 
file that I then put alongside the .lyx file and in LyX's premable I 
issue "\input{preamble.tex}".  Then, I can (un)comment the contained 
behavior in one line.  Naturally, one can use multiple preamble files 
to segregate behaviors.  Using this approach also allows multiple 
documents to share a common preamble.  Further, by symbolically 
linking the .tex file, an update in one instance updates behaviors 
globally.


If one's preamble-related needs have become this sophisticated, then 
I'd recommend this approach. I don't think we really want to implement 
a full-fledged LaTeX editor inside LyX. What might be more plausible, 
and something I think we have considered, is to have some way to 
launch an external text editor and then read back whatever's provided, 
kind of like we do with graphics (say).
We already have line-begin, self-insert and char-delete-forward LFUNs. 
If someone were to add a "for-each-selected-line" LFUN (with a shorter 
name) that would take a command or command-sequence as its argument, 
block comment/uncomment could be done as a macro.


Paul



Re: Toggle comments in Lyx->LaTeX Preamble

2018-02-22 Thread Richard Heck
On 02/22/2018 03:05 PM, Joel Kulesza wrote:
> On Thu, Feb 22, 2018 at 12:52 PM, Daniel Gómez Martínez
> mailto:dangome...@gmail.com>> wrote:
>
> Hello everyone,
>
> I have large sections of customized TeX code in the LaTeX preamble
> of some LyX templates I've created over time. I would like to know
> if there's a way to quickly toggle between commented and
> uncommented line for a given selection of lines (say, with a
> keyboard shortcut)
>
>
> I don't know of a way to do this.
>  
>
> , and in case there's not a quick way to do this, I would like to
> ask the developers if they can include this feature in
> Settings->Document->LaTeX Preamble and in the TeX code environment
>
>
> I would be happy to see this also.
>  
>
> (the one you have with Ctrl+L), it would also be great if a
> message of how to do so (toggle comment lines keyboard shortcut)
> could be included in the Settings->Document->LaTeX Preamble
> sub-window.
>
> I'm sure I've read somewhere that LyX tries to the highest extent
> to be so complete that users don't usually have to put TeX or
> Preamble code lines, but as we users have some really customized
> and variable needs
>
>
> The approach I use is to write a separate, external, preamble.tex file
> that I then put alongside the .lyx file and in LyX's premable I issue
> "\input{preamble.tex}".  Then, I can (un)comment the contained
> behavior in one line.  Naturally, one can use multiple preamble files
> to segregate behaviors.  Using this approach also allows multiple
> documents to share a common preamble.  Further, by symbolically
> linking the .tex file, an update in one instance updates behaviors
> globally.

If one's preamble-related needs have become this sophisticated, then I'd
recommend this approach. I don't think we really want to implement a
full-fledged LaTeX editor inside LyX. What might be more plausible, and
something I think we have considered, is to have some way to launch an
external text editor and then read back whatever's provided, kind of
like we do with graphics (say).

Richard



Re: 回复:help, tex braces

2018-02-22 Thread Scott Kostyshak
On Thu, Feb 22, 2018 at 08:01:20PM +, Andrew Parsloe wrote:

> I ran into this problem some years ago. Guillaume pointed out that this is
> ticket #9348 ("Curly brackets are removed on opening when they should not").

Good to know. Thanks for saving us from a duplicate ticket!

Scott


signature.asc
Description: PGP signature


Re: Toggle comments in Lyx->LaTeX Preamble

2018-02-22 Thread Joel Kulesza
On Thu, Feb 22, 2018 at 12:52 PM, Daniel Gómez Martínez <
dangome...@gmail.com> wrote:

> Hello everyone,
>
> I have large sections of customized TeX code in the LaTeX preamble of some
> LyX templates I've created over time. I would like to know if there's a way
> to quickly toggle between commented and uncommented line for a given
> selection of lines (say, with a keyboard shortcut)
>

I don't know of a way to do this.


> , and in case there's not a quick way to do this, I would like to ask the
> developers if they can include this feature in Settings->Document->LaTeX
> Preamble and in the TeX code environment
>

I would be happy to see this also.


> (the one you have with Ctrl+L), it would also be great if a message of how
> to do so (toggle comment lines keyboard shortcut) could be included in the 
> Settings->Document->LaTeX
> Preamble sub-window.
>
> I'm sure I've read somewhere that LyX tries to the highest extent to be so
> complete that users don't usually have to put TeX or Preamble code lines,
> but as we users have some really customized and variable needs
>

The approach I use is to write a separate, external, preamble.tex file that
I then put alongside the .lyx file and in LyX's premable I issue
"\input{preamble.tex}".  Then, I can (un)comment the contained behavior in
one line.  Naturally, one can use multiple preamble files to segregate
behaviors.  Using this approach also allows multiple documents to share a
common preamble.  Further, by symbolically linking the .tex file, an update
in one instance updates behaviors globally.

- Joel


Re: 回复:help, tex braces

2018-02-22 Thread Andrew Parsloe


On 23/02/2018 8:01 a.m., dongcheng wrote:
Just lyx. when saved .lyx file is opened, multiple braces inserted as 
tex code in math mode  become single one in lyx editor




在2018年02月23日 02:22,Scott Kostyshak 
写道:
On Thu, Feb 22, 2018 at 01:31:35PM +, dongcheng wrote:
> 如何关闭 "打开文件时, 自动去除多余 tex 大括号" 的功能
>
>
> tex code:
> Do not remove the braces , no {{ }} -> {} ,  When the file is
opened.
>
>
> The use of the package ''esdiff'' is affected.

Is this a problem for importing .tex or do you mean just if you
insert
double braces in LyX, they are converted to single braces?

I ran into this problem some years ago. Guillaume pointed out that this 
is ticket #9348 ("Curly brackets are removed on opening when they should 
not").


Andrew


---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus


Toggle comments in Lyx->LaTeX Preamble

2018-02-22 Thread Daniel Gómez Martínez
Hello everyone,

I have large sections of customized TeX code in the LaTeX preamble of some
LyX templates I've created over time. I would like to know if there's a way
to quickly toggle between commented and uncommented line for a given
selection of lines (say, with a keyboard shortcut), and in case there's not
a quick way to do this, I would like to ask the developers if they can
include this feature in Settings->Document->LaTeX Preamble and in the TeX
code environment (the one you have with Ctrl+L), it would also be great if
a message of how to do so (toggle comment lines keyboard shortcut) could be
included in the Settings->Document->LaTeX Preamble sub-window.

I'm sure I've read somewhere that LyX tries to the highest extent to be so
complete that users don't usually have to put TeX or Preamble code lines,
but as we users have some really customized and variable needs, I think
this would be a good feature to have in order to be more productive: we
could then toggle between the customization lines of our templates and
documents for different reasons, be them debugging or changes in document
appearance.

Best regards,


*Daniel Gómez Martínez | Profesional en ingeniería eléctrica*

*Universidad Nacional de Colombi​a​*


回复:help, tex braces

2018-02-22 Thread dongcheng
Just lyx. when saved .lyx file is opened, multiple braces inserted as tex code 
in math mode  become single one in lyx editor




在2018年02月23日 02:22,Scott Kostyshak 写道:
On Thu, Feb 22, 2018 at 01:31:35PM +, dongcheng wrote:
> 如何关闭 "打开文件时, 自动去除多余 tex 大括号" 的功能
>
>
> tex code:
> Do not remove the braces , no {{ }} -> {} ,  When the file is opened.
>
>
> The use of the package ''esdiff'' is affected.

Is this a problem for importing .tex or do you mean just if you insert
double braces in LyX, they are converted to single braces?


Re: help, tex braces

2018-02-22 Thread Scott Kostyshak
On Thu, Feb 22, 2018 at 01:31:35PM +, dongcheng wrote:
> 如何关闭 "打开文件时, 自动去除多余 tex 大括号" 的功能
> 
> 
> tex code:
> Do not remove the braces , no {{ }} -> {} ,  When the file is opened.
> 
> 
> The use of the package ''esdiff'' is affected.

Is this a problem for importing .tex or do you mean just if you insert
double braces in LyX, they are converted to single braces?


signature.asc
Description: PGP signature


help, tex braces

2018-02-22 Thread dongcheng
如何关闭 "打开文件时, 自动去除多余 tex 大括号" 的功能


tex code:
Do not remove the braces , no {{ }} -> {} ,  When the file is opened.


The use of the package ''esdiff'' is affected.

Re: Problem: version control suddenly no longer works in LyX 2.2 and 2.3rc1

2018-02-22 Thread Dr Eberhard Lisse
Pavel,


I didn't know that such a toolbar existed )-)-O More to explore :-)-O

Thank you.

el

On 21/02/2018 17:40, Pavel Sanda wrote:
> Dr Eberhard Lisse wrote:
>> \rcsid{$Id: handbook.lyx,v 1.11 2017/08/12 18:20:59 el Exp $}
>>
>> \newcommand{\versionstring}{v\rcsfilerev,
>> \rcsfileyear-\rcsfilemonth-\rcsfileday}
>>
>> suitable for preamble and/or ERT, page styles or watermarks.
> 
> Do you know you can do such things natively in LyX? Version Control
> Toolbar->Insert Version Info and the select what you want in context
> menu.
> 
> Pavel
> 



Re: older lyx file (around 2009) gives error in lyx2.3.0beta1

2018-02-22 Thread Dr Eberhard Lisse
Typo

On 22/02/2018 13:49, Dr Eberhard Lisse wrote:
[...]
>   find ~/ -name '*lyx' -exec {} lyx -batch --execute ...  {} \;
[...]
should of course read

find ~/ -name '*lyx' -exec lyx -batch --execute ...  {} \;




Re: older lyx file (around 2009) gives error in lyx2.3.0beta1

2018-02-22 Thread Dr Eberhard Lisse
That works well and is quite cool.

But it only works for one file and I could not figure out how how to do
this with

-batch --execute

which would evenually work well as something like

find ~/ -name '*lyx' -exec {} lyx -batch --execute ...  {} \;

on Mac and Linux.

And of course something like this

perl -i.withcurly -0pe 's/\\begin_inset Separator
latexpar\n\\end_inset\n//smi' file.lyx

will convert file.lyx leaving the original in file.lyx.withcurly (for
furture removal) and once one is satisfied one can even do something
like

find ~/ -name '*lyx' -exec perl -i -0pe 's/\\begin_inset Separator
latexpar\n\\end_inset\n//smi' {} \;

which leaves no trace :-)-O

el



On 21/02/2018 17:04, Jürgen Spitzmüller wrote:
[...]
> The following command sequence (to be inserted in the minibuffer)
> removes all latexpar separators in the document and transforms the par
> separator to normal separators:
> 
> command-sequence inset-forall Separator:parbreak inset-modify
> separator plain ; inset-forall Separator:latexpar char-delete-forward
> 
> HTH
> Jürgen
[...]




Re: Probleme bei der Erstellung einer PDF

2018-02-22 Thread Guenter Milde
On 2018-02-21, Tobias Malterer wrote:

Dear Tobias,

> Leider kann ich seit neustem keine PDF Datei erstellen, da diese
> Fehlermeldung erscheint.

This:

> [-- Skipped Type: text/html --]
> [-- Skipped Type: image/png, Filename: image.png --]

is all I can see from your attachments (reading this via the GMANE news
interface). Other users might hesitate to open attachments from unknown
sources.

Please copy the text of the error message (maybe you need to open the
complete log and go to the error there to be able to copy/paste).


> Ich verwende die LYX-Version 2.2 und habe diese heute neu installiert,
> da der Fehler aufgetreten ist.

> Vor der Installation habe ich MikTex und LYX komplett deinstalliert.

Did you also re-install MikTeX?


As this is an English mail list you will get wider reach when writing in
English.

Regards,

Günter