Re:Re: lyxtype and Format version

2016-02-21 Thread subaochen
Thanks PhilipPirrip! Your method just works like a charm:-)


PS,Local Layout is really a good design! A real good start to develop lyx 
module!


At 2016-02-22 00:41:25, "PhilipPirrip"  wrote:
>On 02/21/2016 11:05 AM, subaochen wrote:
>> InsetLayout CharStyle:Function
>
>This should be
>InsetLayout Flex:Function
>
>
>You can read about these in Help>Customization (I must say that's not 
>the clearest part of LyX documentation, though... it's actually very 
>confusing!)
>
>
>Also, if you're writing modules, it's a good idea to test them in 
>Document Settings > Local Layout. There's even a button to convert the 
>layouts to current format.
>


Re: Carriage return in ERT inset

2016-02-21 Thread Jürgen Lange

I want to give feedback (tested with a minimal gnuplot script).
1) double line breaks in ERT: works
2) program listing: fails, because gnuplot script is printed and not  
interpreted

3) paste special > plain text in ERT: works (my preferred method)

Thanks!


Re: Compiling a preview ("teaser") document

2016-02-21 Thread PhilipPirrip

On 02/21/2016 05:22 PM, James wrote:

Maybe a question best suited to the developer list?


I'd first ask at http://tex.stackexchange.com/. There are a few guys 
there who can make everything possible.
Once you have the proper set of commands and environments in LaTeX, 
implementing them in LyX should be relatively easy (layouts, modules...)





Compiling a preview ("teaser") document

2016-02-21 Thread James
Is there a way to compile a document that has particular pages selectively
devoid of legible content? e.g. blurred and turned into a raster image or
simply blanked out with nothing visible and no way to recover the missing
content (i.e. not simply using white text).

Something equivalent to a preview you might distribute without giving away
the content, yet is still the same length (by page count) and ideally
eluding to the actual content (i.e. a blurred image of the actual content)
so that it is still possible to imagine the undisclosed content.

Read on if you are unsure of what I mean.
Having finished writing my PhD dissertation at the beginning of 2015 using
Lyx (which worked out great and included 400+ pages, 100+ graphics and 100+
tables), I have a need to disseminate components of it without giving away
all of the content. The reason being that much of the work is covered by
non-disclosure agreements (NDAs) and as well as some which is commercially
valuable in other ways.

I would like to be able to compile a document and choose to make selected
parts of the thesis which do not contain NDA limitations illegible without
having to create separate documents or by removing pages after compilation
(yes this has been approved by the NDA parties). Keeping things such as the
chapter introductions, contents, index (and other non-restricted content in
front and back matter) would be ideal.

In a perfect situation I would be able to go as far as choosing to blur
particular tables, graphics or even paragraphs which have proprietary
information which cannot be shared (although this seems like a very
difficult scenario to make happen). Maybe a question best suited to the
developer list?

Cheers

This email has been sent from a virus-free computer protected by Avast.
www.avast.com 
<#DDB4FAA8-2DD7-40BB-A1B8-4E2AA1F9FDF2>


Re: Carriage return in ERT inset

2016-02-21 Thread Scott Kostyshak
On Sun, Feb 21, 2016 at 03:15:49PM +0100, David Rörich wrote:
> Hello Jürgen,
> 
> no, not directly. As a single line break is ignored in Latex, Lyx seems to
> remove these single line breaks automatically to make the editor layout
> consistent with the output. I think you have two options here:
> 
> 1) Use double line breaks in the text you paste into the ERT. Lyx will
> convert this to single line breaks in the ERT which translates to a
> whitespace in the output. (see files attached)
> 2) Use the listing environment (Insert > Program listing). Everything you
> insert there will be interpreted verbatim. This is the way to go if you
> would like to insert program code in your document.

I believe that a third option is to do ctrl+shift+v, or Edit > Paste
Special > Plain Text.

Scott


signature.asc
Description: PGP signature


Re: lyxtype and Format version

2016-02-21 Thread PhilipPirrip

On 02/21/2016 11:05 AM, subaochen wrote:

InsetLayout CharStyle:Function


This should be
InsetLayout Flex:Function


You can read about these in Help>Customization (I must say that's not 
the clearest part of LyX documentation, though... it's actually very 
confusing!)



Also, if you're writing modules, it's a good idea to test them in 
Document Settings > Local Layout. There's even a button to convert the 
layouts to current format.




Re: ulem and amsmath

2016-02-21 Thread Michael Berger


On 02/21/2016 04:42 PM, PhilipPirrip wrote:

On 02/21/2016 09:06 AM, Michael Berger wrote:




a) slanted text of the document appeared now upright but underlined
 However, this could easily be reformatted with 'slanted'


What made the text slanted in the first place?



b) there is quite a number of long URLs in my Bibliography that broke
nicely before thanks to Jürgen's special lines in the preamble. Now they
run into the page margin and out of the page.
 And here I would not know ho to fix that.



You may try adding Juergen's special lines below \usepackage{ulem} in

Provides ulem 1
AddToPreamble
  \usepackage{ulem}
  % Juergen's special lines:

EndPreamble





I am confident you have a clue for that as well!? Maybe your first
proposition (change classicthesis-config.tex) is the better alternative?


Best thing would be to ask the maintainer of ulem to fix the bug... 
but that might only come in a few years, knowing how fast things are 
changing in so-1980 LaTeX world.



Thanks Philip,
I will do as you suggests above.

Meanwhile I changed classicthesis-config.tex as screen shot and then 
used underbar in a single word. Unfortunately I faced the same annoying 
loop.


Please, check the change I've made - what did I do wrong?

Michael Berger


lyxtype and Format version

2016-02-21 Thread subaochen
hi all,


I have a very simple character style module as below:


Format 7
InsetLayout CharStyle:Function
LyxType charstyle
LabelString function
LatexType   command
LatexName   function
Font
  FamilySans
EndFont
Preamble
  \newcommand*{\function}[1]{{\texttt #1}}
EndPreamble
End


But when I change Format 7 to Format 49, lyx failed to load the module and said:
LyX: Unknown InsetLayout tag [around line 10 of file 
~/.lyx/layouts/programming.module current token: 'charstyle' context: '']


I have ever tried Format version up to 34, the module works well.


So, where can I get the full information about Format version and their related 
tag? Thanks in advance!


--
Best regards,

Su Baochen

Re: ulem and amsmath

2016-02-21 Thread PhilipPirrip

On 02/21/2016 09:06 AM, Michael Berger wrote:




a) slanted text of the document appeared now upright but underlined
 However, this could easily be reformatted with 'slanted'


What made the text slanted in the first place?



b) there is quite a number of long URLs in my Bibliography that broke
nicely before thanks to Jürgen's special lines in the preamble. Now they
run into the page margin and out of the page.
 And here I would not know ho to fix that.



You may try adding Juergen's special lines below \usepackage{ulem} in

Provides ulem 1
AddToPreamble
  \usepackage{ulem}
  % Juergen's special lines:

EndPreamble





I am confident you have a clue for that as well!? Maybe your first
proposition (change classicthesis-config.tex) is the better alternative?


Best thing would be to ask the maintainer of ulem to fix the bug... but 
that might only come in a few years, knowing how fast things are 
changing in so-1980 LaTeX world.







Re: Carriage return in ERT inset

2016-02-21 Thread David Rörich
Hello Jürgen,

no, not directly. As a single line break is ignored in Latex, Lyx seems to
remove these single line breaks automatically to make the editor layout
consistent with the output. I think you have two options here:

1) Use double line breaks in the text you paste into the ERT. Lyx will
convert this to single line breaks in the ERT which translates to a
whitespace in the output. (see files attached)
2) Use the listing environment (Insert > Program listing). Everything you
insert there will be interpreted verbatim. This is the way to go if you
would like to insert program code in your document.

Regards,
David

2016-02-21 9:38 GMT+01:00 Jürgen Lange :

> Hello,
>
> Code with carriage returns
>
> a
> a
> a
> a
>
> inserted in ERT inset in Lyx appears as
>
> a a a a
>
> Is it possible to keep the carriage returns?
> (This is important in cases with huge parts of code, example: gnuplot
> scripts)
>
> Regards
> Jürgen
>


ert_linebreaks.lyx
Description: application/lyx


ert_linebreaks.pdf
Description: Adobe PDF document


Re: ulem and amsmath

2016-02-21 Thread Michael Berger

On 02/20/2016 11:42 PM, PhilipPirrip wrote:

Hi Michael,
It took me a while to isolate the problem: it's displayed math in 
Chapter03 that causes it. This turned out to be a bug in the package 
ulem:
http://tex.stackexchange.com/questions/125980/problem-with-amsmathfontspeculem 

http://tex.stackexchange.com/questions/120024/pdflatex-hangs-with-no-errors 




In short, the way ulem defines MakeRobust makes amsmath enter an 
infinite loop.



There are a few fixes, I'll give you two:

- either call fixltx2e in classicthesis-config.tex before the call to 
amsmath (CUT & PASTE ABOVE)


- or add te following to ClassicThesis.lyx (main document), Document 
Settings > Local Layout


Provides ulem 1
AddToPreamble
  \usepackage{ulem}
EndPreamble

(don't forget to Validate before pressing Apply)
to make sure ulem is loaded after amsmath.


Let me know if this worked.


LyX calls the two packages in the right order (intentionally or not). 
Unfortunately, the LyX port of the classic thesis template is a bit 
messy as the author of the latex template insisted on keeping many 
unnecessary calls in classicthesis-config.tex

Hi Philip,
I added the lines of code you provided me with to the Local Layout of 
the main document and got some setbacks:


a) slanted text of the document appeared now upright but underlined
However, this could easily be reformatted with 'slanted'

b) there is quite a number of long URLs in my Bibliography that broke 
nicely before thanks to Jürgen's special lines in the preamble. Now they 
run into the page margin and out of the page.

And here I would not know ho to fix that.

I am confident you have a clue for that as well!? Maybe your first 
proposition (change classicthesis-config.tex) is the better alternative?


Cheers,
Michael






Re: anybody using classicthesis-LyX-v4.1 out there ?

2016-02-21 Thread Michael Berger
Michael Berger  online.de> writes:

> 
> Hi Philip,
>
> 
>This issue was solved by Philip and has thus become obsolete
Michael Berger






Re: ulem and amsmath

2016-02-21 Thread Michael Berger

Dear Philip,
Respect! I am truly very grateful to you for resolving this problem! I 
will revert to you after implementing your advice! I think I am going to 
add the respective piece of code to Local Layout of the main document as 
I am reluctant to change something in classicthesis-config.tex.
I also learned that my desperate amateurish attempts to find the cause 
would have lead to nowhere.
Thanks to you and your peers in the world of Open Source for such 
continuous willingness in helping the users.


Re: using Jürgen's modules in classicthesis-LyX-v4.1
He asked me to send a mini example file which I will do within the next 
days.
Perhaps there is a similar cause because I can use those modules in 
KOMA-Script documents whereas in classicthesis Latex already complains 
after I did nothing else but adding csquotes to the list of Modules and 
then tried to compile.


Michael Berger

On 02/20/2016 11:42 PM, PhilipPirrip wrote:

Hi Michael,
It took me a while to isolate the problem: it's displayed math in 
Chapter03 that causes it. This turned out to be a bug in the package 
ulem:
http://tex.stackexchange.com/questions/125980/problem-with-amsmathfontspeculem 

http://tex.stackexchange.com/questions/120024/pdflatex-hangs-with-no-errors 




In short, the way ulem defines MakeRobust makes amsmath enter an 
infinite loop.



There are a few fixes, I'll give you two:

- either call fixltx2e in classicthesis-config.tex before the call to 
amsmath (CUT & PASTE ABOVE)


- or add te following to ClassicThesis.lyx (main document), Document 
Settings > Local Layout


Provides ulem 1
AddToPreamble
  \usepackage{ulem}
EndPreamble

(don't forget to Validate before pressing Apply)
to make sure ulem is loaded after amsmath.


Let me know if this worked.


LyX calls the two packages in the right order (intentionally or not). 
Unfortunately, the LyX port of the classic thesis template is a bit 
messy as the author of the latex template insisted on keeping many 
unnecessary calls in classicthesis-config.tex























Re: Smart/curly quotes vs straight quotes

2016-02-21 Thread dajare
The global search/replace can be done in OpenOffice using the instructions
contained in this Q on the AskLibO site:

https://ask.libreoffice.org/en/question/2612/how-do-i-convert-straight-quotes-to-typographic-quotes/?answer=7010#post-id-7010

The regex works pretty well in my experience, and it is at least worth a
look since you have this software already.



--
View this message in context: 
http://lyx.475766.n2.nabble.com/Smart-curly-quotes-vs-straight-quotes-tp3579497p7580331.html
Sent from the LyX - Users mailing list archive at Nabble.com.


Carriage return in ERT inset

2016-02-21 Thread Jürgen Lange

Hello,

Code with carriage returns

a
a
a
a

inserted in ERT inset in Lyx appears as

a a a a

Is it possible to keep the carriage returns?
(This is important in cases with huge parts of code, example: gnuplot  
scripts)


Regards
Jürgen