Re: Index not printing

2018-03-16 Thread Richard Heck
On 03/15/2018 09:07 PM, David White wrote:
> Hi,
>
> For some reason, indexes are not being produced with pdflatex.
>
> I started noticing this around the time of upgrading MiKTeX to the
> latest (64-bit) version.  I have created several documents with
> indexes (single and multiple) in the past, so I am rather baffled.
>
> If I open the LyX User's Guide from the Help menu and hit View [PDF
> (pdflatex)], an index is not printed.  If I create a brand new
> document, type some text, insert an index entry (using the menu) and
> insert an index, an index is not printed.
>
> The "Default" Processor is set in Document Settings > Index Generation.
>
> Strangely, the idx file is created and there are no errors or warnings
> in the logs.
>
> Has anyone seen this before? 
>
> Any thoughts on what might be causing this issue.

Have you looked over the LaTeX log? That should give you some hints. It is
possible, I'd think, that the index program is not in the path, or
something like that.

RK



Re: Miktex vs Texlive

2018-03-12 Thread Richard Heck
On 03/12/2018 12:39 PM, Michael Berger wrote:
>
> Thanks Richard,
>
> my son is using Windows 10, not Lyx. But I learned from Kornel and Uwe
> that his file should nevertheless compile if opened in LyX. Did I get
> something wrong here?:-(
>

Was the file your son created a pure LaTeX file? Or was it a LyX file?
If the former, I take it
that you imported it into LyX.

Either way, if you want to send me, privately, the file your son sent
you, then I can have a look
and see if I can figure out what's wrong.

Richard


> On 12.03.2018 16:54, Richard Heck wrote:
>> On 03/12/2018 08:12 AM, Michael Berger wrote:
>>>
>>> Hello Uwe, Kornel, thanks for offering your help.
>>>
>>> My son created this Beamer file under Windows 10 on his Laptop and
>>> presented it to an audience just a few days ago without facing any
>>> problem. However, on my desktop, Lyx 2.2.3, Mageia 6, it fails to
>>> convert to PDF. See below the corresponding LaTeX log file.
>>> I also attach my son's PDF output generated under Windows 10.
>>
>> We should have asked a simpler question first: What version of LyX is
>> your son using?
>>
>> That said, I think the problem is here:
>>
>>> ** mdframed patching \endmdf@trivlist
>>>
>>>
>>> ** -- failed**
>>>
>>
>> You then end up with a lot of errors that look like:
>>
>>> ! LaTeX Error: \begin{list} on input line 297 ended by
>>> \end{beamer@framepauses} 
>>
>> Possibly this could be due to different versions of the mdframed
>> package on the two systems,
>> but I do not know how of why that package is being used here, so it
>> is hard to say.
>>
>> Richard
>>
>



Re: Miktex vs Texlive

2018-03-12 Thread Richard Heck
On 03/12/2018 08:12 AM, Michael Berger wrote:
>
> Hello Uwe, Kornel, thanks for offering your help.
>
> My son created this Beamer file under Windows 10 on his Laptop and
> presented it to an audience just a few days ago without facing any
> problem. However, on my desktop, Lyx 2.2.3, Mageia 6, it fails to
> convert to PDF. See below the corresponding LaTeX log file.
> I also attach my son's PDF output generated under Windows 10.

We should have asked a simpler question first: What version of LyX is
your son using?

That said, I think the problem is here:

> ** mdframed patching \endmdf@trivlist
>
>
> ** -- failed**
>

You then end up with a lot of errors that look like:

> ! LaTeX Error: \begin{list} on input line 297 ended by
> \end{beamer@framepauses} 

Possibly this could be due to different versions of the mdframed package
on the two systems,
but I do not know how of why that package is being used here, so it is
hard to say.

Richard



Re: Miktex vs Texlive

2018-03-11 Thread Richard Heck
On 03/11/2018 01:25 PM, Jean-Marc Lasgouttes wrote:
> Le 11/03/2018 à 18:09, Richard Heck a écrit :
>> On 03/11/2018 01:05 PM, Michael Berger wrote:
>>> Thanks Uwe and Kornel,
>>>
>>> I am somewhat puzzled. My son sent me a LyX document produced on his
>>> Windows laptop.
>>>
>>> I opened it with LyX under Linux but got heaps of errors when trying
>>> to compile it to PDF.
>>>
>>> What am I getting wrong here?
>>>
>>> Sorry, I am just an ordinary layman!
>>
>> Probably you do not have certain packages installed, though I gather
>> that MiKTeX is
>> supposed to install them on the fly. 
>
> It is the other way round: document produced with miktex but read with
> texlive. But your advice it correct about log file is still fine!

Oh, whoops, yes. In that case, we definitely need to log file.

Richard



Re: Miktex vs Texlive

2018-03-11 Thread Richard Heck
On 03/11/2018 01:05 PM, Michael Berger wrote:
> Thanks Uwe and Kornel,
>
> I am somewhat puzzled. My son sent me a LyX document produced on his
> Windows laptop.
>
> I opened it with LyX under Linux but got heaps of errors when trying
> to compile it to PDF.
>
> What am I getting wrong here?
>
> Sorry, I am just an ordinary layman!

Probably you do not have certain packages installed, though I gather
that MiKTeX is
supposed to install them on the fly. In any event, if you can post the
errors you are
getting, then we can help. Go to Document> LaTeX Log. You can either cut
and paste
what's there, or hit "Open Containing Directory" and attach the *.log file.

RK


> On 11.03.2018 17:38, Kornel Benko wrote:
>> Am Sonntag, 11. März 2018 17:30:30 CET schrieb Michael Berger
>> :
>>> Dear Lyx users,
>>>
>>> is there a way to convert a LyX document made with MikTeX (Windows)
>>> in a
>>> LyX TeXLive (Linux) document?
>>>
>>> Thanks and best,
>>>
>>> Michael
>> There should be no difference regarding lyx.
>> Documents are written by lyx, not be MikTeX or TeXLive.
>> Even exported to latex source is the same on all platforms.
>>
>> Kornel
>



Re: How to add/change/delete styles, the new way?

2018-03-05 Thread Richard Heck
On 03/05/2018 09:51 PM, Steve Litt wrote:
> Hi all,
>
> I've used LyX since 2001 so I got used to adding, changing and deleting
> environments and paragraph styles by using a separate layout file to
> create a new document class based on the document class I want to
> modify (typically Book). It works.
>
> But now I'm presenting Linux Content Editing at GoLUG, LyX is a part of
> it, and I'd like to present the newer method of adding, changing and
> deleting styles (environments and paragraph styles). I forgot what that
> new way was, how to use it, and where to learn about it. Could you
> refresh my memory?

There are two options.

One: Use a "module". Think:
    LyX layouts are to LaTeX document classes as LyX modules are to
LaTeX packages
I.e., modules are for alterations, new features, etc, that are not
document-specific but aren't worth a full new document class. You can do
anything in a module you can do in a layout file. They're dynamic
includes, if you like.

User modules should go into $USERDIR/layouts/, and have the extension
".module". You need to reconfigure LyX after adding a new one in order
to see it under Document> Settings> Modules. Note that you can edit
these without restarting if you use the (officially discouraged) LFUN
"layout-reload" in the minibuffer to, uh, reload. (I added that for you.)

Two: Use "Local Layout", which you will find under Document> Settings.
This is for layout informatios really is document-specific. Say, you
need a character style, but really only for this document. Then put that
into Local Layout. These are reloaded every time you edit, so they can
be 'worked on' live. But maybe not on a production document?

The syntax is the same in both cases. See Chapter 5 of the Customization
manual for all the details.

Richard



Re: AW: AW: Problem with lyx-archiv (zip)

2018-03-05 Thread Richard Heck
On 03/05/2018 11:21 AM, a...@andreashegenbart.de wrote:
>
>> -Ursprüngliche Nachricht-
>> Von: lyx-users@lists.lyx.org  Im Auftrag von Kornel
>> Benko
>> Gesendet: Montag, 5. März 2018 16:04
>> An: lyx-users@lists.lyx.org
>> Betreff: Re: AW: Problem with lyx-archiv (zip)
>>
>> Am Montag, 5. März 2018 15:22:21 CET schrieb a...@andreashegenbart.de:
>>> I´ve to correct the file name - it was:
>>>
>>> “python -tt $Ss/scripts/lyxpak.py”
>> Should have been
>>  python -tt $$s/scripts/lyxpak.py” something This is the converter lyx 
>> -->
>> lyxgz
>>
>> You are probably missing some needed programs like 'gzip'; At least, this is 
>> used
>> on linux.
>>
>>  Kornel
> Thanks Kornel,
> I first used winzip; now I installes gzip, reconfigured Lyx,  but the problem 
> remains.

Can you post the full error message?

Richard



Re: Customizable Lists (enumitem) issue

2018-02-24 Thread Richard Heck
On 02/24/2018 10:06 AM, Jürgen Spitzmüller wrote:
> Am Samstag, den 24.02.2018, 16:00 +0200 schrieb Dr Eberhard Lisse:
>> Hi,
>>
>> I have created a template which uses the above module and sets up
>> stuff
>> like:
>>
>>  \setenumerate[1]{label*=\arabic*., ref=\arabic*}
>>
>> in the preamble.
>>
>> If I use a (numbered) list in the text, enumitem.sty is loaded, hence
>> the above works, but if I don't enumitem.sty is not loaded and the
>> above
>> generates an error.
>>
>> I enclosed a MWE, just make the word test a list (enumerate or
>> itemize)
>> and the error should go away.
>>
>> Can that be considered a bug?
> No. This is by design.
>
>> Is there a workaround?
> \@ifpackageloaded{enumitem}{%
> 
> }{}

Alternatively, in the module itself (or wherever the layout is), put
that code
into the Preamble section for the Enumerate style, e.g.:

Style Enumerate
    Preamble
        \setenumerate[1]{label*=\arabic*., ref=\arabic*}
    EndPreamble
End

Note that this would over-write any previous Preamble declaration, though.
Probably we should have an AddToPreamble for these, too.

Richard



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
>>> <dangome...@gmail.com <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 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
> > 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: older lyx file (around 2009) gives error in lyx2.3.0beta1

2018-02-19 Thread Richard Heck
On 02/19/2018 10:40 AM, Jürgen Spitzmüller wrote:
> Am Montag, den 19.02.2018, 13:01 +0100 schrieb Kornel Benko:
>> OK, got it down to this:
> Excellent. Here is my analysis. 
>
> Since this is a very old document, it has "\layout Standard" in insets.
> Now as of format 315 (for LyX 1.6), we switched to "\begin_layout
> PlainLayout" and shortly afterwards "\begin_layout Plain Layout" inside
> insets. But we do not actually convert "Standard" to "Plain Layout"
> (probably since it is hard to predict where to do that and since we
> rely on LyX doing that anyway), so the insets keep having
> "\begin_layout Standard".
>
> Now the convert_separator routine (format 475) checks whether we are
> inside a text inset precisely by looking for "Plain Layout". This of
> course fails here, hence the separator is inserted (lyx_2_2.py:186ff.)
>
> I am not sure if there is an easy fix for this. The "real" fix would be
> to actually change Standard to PlainLayout in 315, but I suppose there
> were reasons for not doing that.

The one you mentioned, basically: Whether to use PlainLayout is set by
information in the layout files (ForcePlain), to which we do not have
access.

But you found a solution, so good!

Richard



Re: quantifiers in lyx

2018-02-18 Thread Richard Heck
On 02/18/2018 04:48 PM, Jean-Marc Lasgouttes wrote:
> Le 18/02/2018 à 13:37, mike a écrit :
>> Dear list
>>
>> Is there a way to get quantifiers without ERT?
>
> Hello,
>
> What kind of quantifiers do you have in mind?

Probably he means logical quantifiers, like ∀ and ∃.

These can be entered in math mode. Just hit Ctrl-M to enter math mode, and
then you can enter them as LaTeX: \forall, \exists, etc. Or you can
choose them
from the math toolbar that pops up. They are on the menu with the upside
down Δ.

Richard




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

2018-02-18 Thread Richard Heck
On 02/18/2018 01:46 PM, Wolfgang Engelmann wrote:
>
> I am including a lyx file which is part of an older lyx file (around
> 2009) and run by lyx2.3.0beta1.
>
> The error message (see below) after producing a pdf file was due to an
> arrow-type sign at the end of an index entry. If removed, it works.
>
> Since it took me quite some time to find out, I thought to report on
> it, to safe others time and nerves who run into it. This sign did not
> exist in the original and occurs after importing the file into the new
> lyx version. It's mainly found at the end of an index entry, but also
> at the end of some legends or even at the end of some sections,
> chapters...
>
> I tried to copy the sign here, but it gave this vertical space seen
> below. It might just be an empty space which has been transformed into
> this sign during the conversion. Would be helpful to eliminate it by
> adjusting the newer versions.
>

This is definitely a bug. I'm not sure why that's being added there.

Richard



Re: Just Do It! — Long Export Process Halted to Query Continuation

2018-02-16 Thread Richard Heck
On 02/16/2018 11:46 PM, Daniel Kian Mc Kiernan wrote:
> On 02/16/2018 07:37 PM, Scott Kostyshak wrote:
>> On Sat, Feb 17, 2018 at 03:19:38AM +, Mc Kiernan Daniel Kian wrote:
>>> On 02/16/2018 05:53 PM, Scott Kostyshak wrote:

 You do not need to babysit it. Actually the process should keep going
 even if you don't click a button.
>>>
>>> Perhaps you're correct, but the process seems to stop, based upon the
>>> reported actions in the lower left-hand field.
>>
>> Agreed. I did not mean to say that LyX's behavior is ideal. I just
>> wanted to let you know you did not need to babysit.
>
> Okay, so basically just ill-considered use of a modal dialog box, the
> modality of which is just within the interface.  Thank you for that
> information!

It would probably be a very easy fix to make the dialog non-modal.

FYI, the reason we have this at all is to make it possible for people to
stop processes that are going on too long. As Scott sort of said, once
we have the ability to cancel this kind of thing, the timeout may no
longer be necessary. But that is still a bit buggy.

Richard




Re: Small poll - download speed of LyX installers

2018-02-16 Thread Richard Heck
On 02/16/2018 11:20 AM, Pavel Sanda wrote:
> Hello lyx users,
>
> it has been brought to our(=developers) attention that downloading speed of 
> lyx
> installers might become too slow on various places over the globe. The size of
> installers was steadily growing past years and 220 MB might indeed pose 
> problem
> in case users end up with connections speeds about ~10kbs...
>
> That's why this small poll - we would be intersted to know how bad the 
> situation
> generally is -- especially outside of Europe.
>
> If you have one minute of spare time could you download this file
> ftp://ftp.lyx.org/pub/lyx/devel/lyx-2.3/lyx-2.3.0rc2/LyX-2.3.0rc2+qt5-x86_64-cocoa.dmg
> and report:
>
> 1. time to download (/ download speed)
> 2. country (and/or domain) where you download from
> 3. whether you download from home/academic network/large company...
> (you don't have to report more details than it feels comfortable...)
>
> Both good and bad answers matter, we want to know whether this is sporadic
> or widespread problem.
>
> In case your download of the link above is more than couple seconds, it would
> be useful if you also reported whether some of the mirror servers listed at
> http://www.lyx.org/Download#toc11 which are closer to your geographical
> location perform better.

Hi, Pavel,

I am in a hotel in Austin TX at the moment, so using the hotel's wifi.
Downloading from ftp.lyx.org, I'm seeing speeds fluctuating between
about 20KB/s and 100KB/s (so, no, I didn't wait the whole hour to see
how it worked out). The UCSD mirror gave me 2.89MB/s. Just for kicks, I
tried the South Africa mirror, as well. That gave me an average 1.42MB/s
(and was over 2MB/s at times). Greece gave me 163KB/s, though it was
often higher than that.

Richard



Re: lyx2.3.0beta1 lyx-file export not taken by lyx2.2.3

2018-02-15 Thread Richard Heck
On 02/15/2018 10:47 AM, Guenter Milde wrote:
> On 2018-02-15, Wolfgang Engelmann wrote:
>
>> [-- Type: text/plain, Encoding: 8bit --]
>> Is it true, that a lyx-file produced by lyx2.3.0beta1 is not taken by 
>> lyx2.2.3?
> Yes. However, you can use File>Export>LyX 2.2 to save a version that can be 
> opened by LyX 2.2.

I'll just add that LyX 2.2.4 will be able to read 2.3.0 files. This is
always true of the last version before a new major version.

Richard

PS If you just copy the new lyx2lyx files from here:
   
http://git.lyx.org/?p=lyx.git;a=tree;f=lib/lyx2lyx;h=014d8bb452cf359819192d1796d65f9b10299a79;hb=HEAD
into your 2.2.3 directories, then it will be able to read 2.3.0 files, too.



Re: LyX-to-LyX pasting from "English" to "English (USA)" annoyances

2018-01-20 Thread Richard Heck
On 01/20/2018 05:39 PM, Scott Kostyshak wrote:
> I have a paper where I set the language to "English (USA)". I am not
> normally so patriotic, but I do this to get the conventional quoting
> used in USA journals where punctuation in the references are inside the
> quotation marks, e.g., <<"This is a Title.">> instead of <<"This is a
> Title".>>. I could instead set the language of Biblatex directly so the
> following issue would not matter, but I am stubborn.
>
> Most of my other .lyx files use the language "English", and so whenever
> I paste from one of those .lyx files into my "English (USA)" .lyx file,
> the pasted text is (correctly) marked with a blue line because it is a
> different language, "English". I then just need to select the text I
> just pasted in and change it from "English" to "English (USA)." I do
> this maneuver enough times that I find it annoying.
>
> Does anyone else run into this annoyance, e.g., with other forms of
> English, French, German, etc? If not, then I don't think we should
> change anything.
>
> If others do find this annoying, perhaps we can think of an improvement.
> The ideal behavior for me would be that whenever I paste text that is in
> language "mylanguage (x)" into a document that has language "mylanguage
> (y)" and no other language, the text would be pasted as
> "mylanguage (y)". However, thinking about what the LyX behavior should
> be, I don't know what to suggest. On the one hand, I don't think we
> should change the default behavior since it is correct to treat
> "mylanguage (x)" and "mylanguage (y)" as different languages.
> On the other, I don't think this is a big enough issue that we should
> have a preference for it. So I don't know what to suggest.
>
> Thoughts?

Maybe another form of "paste special" that would just ignore the
language? That would probably take care of most of the use cases here.

Richard



Re: How to extend a standard layouts

2018-01-20 Thread Richard Heck
On 01/20/2018 11:30 AM, racoon wrote:
> By default LyX loads standard layouts and insets. Is there a way to
> extend them without overwriting the default .inc file and without
> using a module?
>
> Let's say I want to extend the standard Note style.
>
> I don't want to use a module since I want to make a non-optional
> change to the Note inset. For example, I want to use another font size
> for all LyX notes.
>
> If I understood correctly, I can just put a copy of the stdinset.inc
> file from the library to the user directory. But this will have the
> unwelcome effect to overwrite whatever is in the stdinset.inc in the
> library directory. So, to avoid unwanted consequences, I will have to
> update my user stdinset.inc every time the library stdinset.inc
> changes, for example, in a new version of LyX.

I have run into this problem, too. Some form of it will arise any time
you want to emend or amend a layout file.

I wonder if a longer-term solution is required, then. Might there be
some way we could have 'extensions' of this kind? Maybe they could be
named things like stdinsets.inc.ext and they would always be loaded
after the corresponding other file was.

Richard



Re: suppression of footnotes in TOC

2018-01-02 Thread Richard Heck
On 01/02/2018 03:10 PM, Ricardo Berlasso wrote:
> 2018-01-02 16:57 GMT+01:00 Ekkehart Schlicht  >:
>
> Hi,
>
> I have footnotes to section headings (that are necessary because
> some sections are taken from earlier articles, and this is
> explained in those footnotes). In the TOC, these footnotes
> re-appear. It is quite clumsy to repress them in those cases by
> using \section* instead of \section and add
> \addcontentsline{section}{12 sectionname}. It would be very
> convenient to have footnoes to TOC entries omitted by defaultin
> the TOC.
>

Yes, this seems right, and it shouldn't be too difficult. Feel free to
file this as a bug. If you do, please cc me (rgheck). This may not be
terribly difficult.

Richard



Re: Indexing concepts

2017-12-31 Thread Richard Heck
On 12/31/2017 11:01 AM, Rich Shepard wrote:
>   I've read the index sections in the User Guide and did not see how
> to add
> a concept to the index. Here's a contrived example.
>
>   A handbook for long distance truckers does not have a section on
> 'compliance' but the indexer knows that readers will look for
> 'compliance'
> or 'complying' in the index. The index should have a main heading and
> subentries something like this:
> compliance with
>     full bladder
>     rest periods
>     speed limits
>     trip log
>     weigh stations
>     weight limits
>
>   Each subentry has a reference indicator which is found in the text
> and can
> be marked using Insert -> Index. How can the conceptual term be
> entered as a
> header?

6.6.1: These should all be entered as "compliance with!full bladder",
etc. The
exclamation point marks grouping levels.

Richard



Re: Is it possible to apply document defaults

2017-10-31 Thread Richard Heck
On 10/31/2017 03:44 PM, racoon wrote:
> On 25.10.2017 22:07, Richard Heck wrote:
>> On 10/24/2017 09:37 AM, racoon wrote:
>>> Hi
>>>
>>> I know of the "Save as Document Defaults" in the document settings.
>>> What it seems to do is create a default document with preferences that
>>> is loaded when one creates a new document.
>>>
>>> However, if I have created a number of documents using those defaults
>>> and discover that I would like to have something differently, is it
>>> possible not only to save the new settings to the defaults for new
>>> documents but also apply those defaults withing other already existing
>>> documents?
>>>
>>> I guess I am missing an "Apply Document Defaults" button in settings.
>>> But maybe there is a different way in LyX to do this.
>>
>> There's no way in LyX to do this, but the fact that LyX files are just
>> text files makes it easy to do outside LyX. One option is to write a
>> really basic filter and then run it on your files. For example, if you
>> wanted to use refstyle, whereas you hadn't previously, you could just
>> do:
>>  perl -ibak -pe 's/\\use_refstyle 0/\\use_refstyle 1/' *.lyx
>> Of course, if it's just that one thing to change, that's maybe not so
>> helpful. But if there were several changes
>>
>> Many people use similar techniques to make all kinds of changes to LyX
>> files. Just as an example, I'm attaching a Perl script I used a little
>> while ago to change all citations to a particular book to citealias-type
>> citations. I prefer to write these things in Perl, since it was more or
>> less designed for this sort of thing. But you could also do it in
>> Python, of course, or sed or awk, if you're really masochistic.
>
> Thanks Richard. I will have to look into it when my changes to the
> default get too many to keep track of them and do them manually for
> all the older documents. But wouldn't this be a nice feature to have
> in LyX right next to the Save Defaults button? Maybe your script could
> be used for that?

It's a reasonable request. Note, however, that it would essentially
involve replacing all the Document settings, at least if we really want
to use the defaults.

Actually, come to think of it, here's another way to do it: Create a new
document; cut and paste the content of the old one.

Richard



Re: Is it possible to apply document defaults

2017-10-25 Thread Richard Heck
On 10/24/2017 09:37 AM, racoon wrote:
> Hi
>
> I know of the "Save as Document Defaults" in the document settings.
> What it seems to do is create a default document with preferences that
> is loaded when one creates a new document.
>
> However, if I have created a number of documents using those defaults
> and discover that I would like to have something differently, is it
> possible not only to save the new settings to the defaults for new
> documents but also apply those defaults withing other already existing
> documents?
>
> I guess I am missing an "Apply Document Defaults" button in settings.
> But maybe there is a different way in LyX to do this.

There's no way in LyX to do this, but the fact that LyX files are just
text files makes it easy to do outside LyX. One option is to write a
really basic filter and then run it on your files. For example, if you
wanted to use refstyle, whereas you hadn't previously, you could just do:
    perl -ibak -pe 's/\\use_refstyle 0/\\use_refstyle 1/' *.lyx
Of course, if it's just that one thing to change, that's maybe not so
helpful. But if there were several changes

Many people use similar techniques to make all kinds of changes to LyX
files. Just as an example, I'm attaching a Perl script I used a little
while ago to change all citations to a particular book to citealias-type
citations. I prefer to write these things in Perl, since it was more or
less designed for this sort of thing. But you could also do it in
Python, of course, or sed or awk, if you're really masochistic.

Richard

PS The cite*alias commands are supported by an updated citeengine I
wrote, which I've also attached, again as an example. If you search for
"alias" you'll find what I added.

(which I'd written a new citeengine file to support, also attached, also
as an example).



citealias.pl
Description: Perl program
# \DeclareLyXCiteEngine[natbib.sty]{Natbib (Modified)}
# DescriptionBegin
#   Natbib supports a range of both author-year and numerical styles mainly
#   aimed at the Humanities. It features automatic sorting and merging of
#   numerical citations, annotations, capitalization of the `van' part of
#   author names, shortened and full author lists, and more.
# DescriptionEnd

# Author: Julien Rioux 

Format 63

Requires natbib

# The framework (biblatex|bibtex)
CiteFramework bibtex

# Cite style variants (default|authoryear|natbib)
# We provide both authoryear and numerical citations
CiteEngineType authoryear|numerical

# Default style files for either engine type
DefaultBiblio  authoryear:plainnat|numerical:plainnat

# Maximum number of names before "et al." chimes in
MaxCiteNames 2


# The syntax of the cite command definitions below is:
# LyXName|alias*[][]=latexcmd
# 
# * LyXName:  The LyX name as output in the LyX file. For
# portability reasons, we try to use the same
# name for same-formatted commands in the
# different engines (thus many names stem from
# natbib).
# * Alias:A (comma-separated) list of commands that fall
# back to the given LyX name in the current engine.
# This is a bit like "ObsoletedBy" in the layouts.
# * latexcmd: The actual LaTeX command that is output.
#
# Alias and latexcmd are optional. If no latexcmd is given, the
# LyXName will be output to LaTeX.
#
# Note further:
#
# * The LyXName "keyonly" has a special meaning: only the citation key,
#   without any latex command, is output.
# * Capitalization indicates that the command also has a capitalized
#   form (\Latexcmd vs. \latexcmd). These usually enforce upcasing of
#   name prefixes (von Goethe => Von Goethe).
# * Brackets [] indicate the number of optional arguments (0, 1, 2).
# * The star * indicates there is a starred version of the command
#   (\latexcmd* vs. \latexcmd). By default, the starred version means:
#   Expand the author list even if the maxnames setting would cause
#   BibTeX/Biber to shorten it with "et al.".
#   If the star has a different meaning for a command, it can be
#   specified in angle brackets: .
#   Maximal two translatable macro keywords, marked by the prefix '!_',
#   can be given. The first points to the string that replaces the
#   "Full aut list" checkbox label in the Citation dialog, the
#   second one an optional tooltip for this checkbox. Note that these
#   two macros have to be defined in the CiteFormat section (see below),
#   dropping the '!' from the prefix (see below), e.g.:
#   _stardesc Starred command label
#   _stardesctooltip Tooltip for the starred command checkbox.

#
# CITE COMMAND DEFINITIONS for either engine type
#
CiteEngine authoryear
Citet*[][]
Citep*[][]
Citealt*[][]
Citealp*[][]
Citeauthor*[]
citeyear[]
citeyearpar[][]
citetalias[][]
citepalias[][]
nocite
keyonly
End

CiteEngine numerical
Citep*[][]
Citealp*[][]
Citet*[][]

Re: Cross-reference with /vref not mentioning the page in preview

2017-10-17 Thread Richard Heck
On 10/17/2017 03:29 PM, Alexandru Guzu wrote:
> Hello,
>
> I am following the LyX tutorial and I am having some difficulties with
> the Cross-referencing.
>
> The tutorial says:
> "
> select the drop-down menu labeled “Format” and select “ on
> page ”. Then select “sec:About-This-Document” (it may be
> selected by default), and a reference marker will appear containing
> “Ref+Text: sec:About-This-Document”
> ...
> In the printed document, this reference marker will be replaced with
> the section number and then the page number.
> "
> However, this is not the case. The page number or any page reference
> is nowhere to be found.

This part of the tutorial is a bit misleading. The \vref command is
smart enough to know when the item it is referencing is on the same
page. In that case, it omits the "on page N" part. It looks to me as if
this has been fixed for the next release.

Richard



Re: Custom inset without input box

2017-10-16 Thread Richard Heck
On 10/13/2017 04:32 PM, Christian Eriksson wrote:
>
> Hi,
>
>  
>
> I am creating a custom layout and I want to create an inset which does
> not take any input, an example would be the ”new page” inset from
> ’Insert->Formatting->New Page’. The purpose would be not to confuse
> users by making them think that they need to input something. If this
> is not possible can I pre fill the input box and then suppress the
> output in the compiled document?
>

There's no way to make input impossible, but you can suppress output
simply by having the corresponding LaTeX command not do anything. E.g.:
 \newcommand\donothing[1]{}
I believe some of the modules actually use this trick, though with
layouts. E.g., you could create a simple new page "layout" roughly as
follows:

    Style NewPage
        LatexType Command
        LatexName donothing
        LabelType Static
        LabelString "--- New Page --- (input ignored)"
        Preamble
            \newcommand\donothing[1]{}
        EndPreamble
        Font
            Color Red
            Series Bold
        EndFont
        # Essential if we want to allow for no input
        KeepEmpty 1
    End

Note that you could equally well have this "layout" issue some command.
I've been meaning for some time to add such a layout to the Endnotes
module, that would issue \theendnotes.

Something similar could be done with an inset.

Richard



Re: AMS Article: need Theorems, and SUBSECTIONS to share counter.

2017-10-03 Thread Richard Heck
On 10/03/2017 06:41 PM, rls wrote:
> Thanks once more!
>
> I truly understand the need to RTFM, but sometimes one is tired, just
> looking for a quick fix (having gone through Pascal, 8086 assembly, C,
> LateX Java, ML, and programmed a half dozen editors...)

I understand, of course, and did not mean to tell you to RTFM, as fine
as it is. Just, if you do want to understand the details.

> I just got the following question:
> Why not reverse the process; Rather than modifying a dozen styles?
> What would it take to create something like a "Subsection-v2" which
> would just use as counter the "thm" counter?

This can be done, but it would mean creating your own version of
theorems-ams. It's easy to do this by copying the old files to new names
(in $USERDIR/layouts/) and then modifying them. I'll be happy to explain
the process a bit more if you want to do that.

The reason you have to modify so many styles is that all the
declarations happen in Theorem, and then the other styles copy them. But
the copying happens when the file is originally read: Later
modifications to Theorem do not affect, say, Lemma. And each individual
counter (e.g., "Lemma \thesubsection") has to be declared independently,
anyway. Presumably, there would be a way to fix that, but no one has
ever really needed to do it, so it doesn't get done.

Richard



Re: AMS Article: need Theorems, and SUBSECTIONS to share counter.

2017-10-03 Thread Richard Heck
On 10/03/2017 03:35 PM, rls wrote:
> Thank you for your reply.
> I have tried your suggestion verbatim (after correcting a couple of
> misprints): modifying "Local Layout".
>
> I don't really understand the details, 

See Ch 5 of the Customization manual again, and have a look at the file
theorems-ams.inc, where the original definitions of these styles are.
What we're adding to Local Layout is just modifying those definitions.
The syntax takes a bit of getting used to, but it's not too bad, really.

> but I noticed one problem:
> - Inside a given section (say section 2), the theorem and lemma
> numbers are all displayed as "2.0".
> - The subsection numbers are displayed correctley
> - Printing gives correct results.

Sorry, I hadn't tested. You need also to add:

LabelString "Theorem \thesubsection."

and similarly for lemmas. Note that, if you want to use things other
than theorems and lemmas, you'll need to add similar modifications for
those styles.

You should also put, at the top of the Local Layout, "Format 60", that
being the 2.2.x format. This will avoid any possible problems from LyX
thinking you intend some other version.

Richard




> =
> On 03/10/2017 17:15, Richard Heck wrote:
>>
>> The LyX display is controlled by 'layout' information, which is defined
>> in a number of places:
>>
>> (i) The layout file for the document class (e.g., amsart.layout)
>> (ii) Modules, which are to LyX as packages are to LaTeX (e.g.,
>> theorems-ams.module)
>> (iii) Document-specific "local" layout, found at Document> Settings>
>> Local Layout
>>
>> It seems to me as if you will probably be best off creating a new module
>> of your own, perhaps starting with and modifying theorems-ams.module.
>> Documentation concerning this is in Ch 5 of the Customization manual. As
>> far as the counters are concerned, you will want to modify the
>> LabelCounter defined for the various styles so that it uses the one for
>> subsections.
>>
>> Note that you can just make modifications in Local Layout, e.g.:
>>
>> Style Theorem
>>  LabelCounter subsection
>>  Preamble
>>      \theoremstyle{plain}
>>  \newtheorem{thm}[subsection]{\protect\theoremname}
>>  EndPreamable
>> End
>> Style Lemma
>>  LabelCounter subsection
>>  Preamble
>>      \theoremstyle{plain}
>>  \newtheorem{lem}[subsection]{\protect\theoremname}
>>  EndPreamable
>> End
>>
>> Then you could just use the usual Theorems (AMS) module, and these
>> modifications might be enough to get you what you want. But if you are
>> going to want to re-use them, then putting them in a module of their own
>> will make that easier.
>>
>> Richard
>


Re: Unable to open file on older version 2.0.8.1

2017-10-03 Thread Richard Heck

Kim,

Please send the file privately to me (rgh...@lyx.org), if that is
possible. I will be able to
figure out what is wrong pretty quickly.

Another option: Run LyX from a terminal and try to open the file. You
should see some
more detailed error messages. Post them here---though you may also be
able to tell what
is wrong yourself, once you see them.

Richard



On 10/03/2017 12:30 PM, John Kane wrote:
> Just to be a pedant, I think it is Ubuntu 16.04.
>
> On 3 October 2017 at 10:14, Tim Q  > wrote:
>
> Hi Scott, 
> Thanks for your prompt response. 1/ I'm currently using Ubuntu
> version 16.4. 
>
> 2/ I created a file using Lyx version 2.0.8.1 which is my back up
> file.
>
> 3/ I installed Ubuntu 16.4 and Lyx 2.2.2 from Ubuntu software
> application.
>
> Now I get this message trying to open my backup file. 
>
> "Myreading.lyx is from an older version of LyX and the lyx2lyx
> script failed to convert it."
>
> Kind regards, 
> Kim 
>
>
>
>
>
>
>
> On Oct 2, 2017 10:42 PM, "Scott Kostyshak"  > wrote:
>
> On Mon, Oct 02, 2017 at 11:29:50PM +, Tim Q wrote:
> > hi,
> >
> >
> > "" Myreading.lyx is from an older version of LyX and the
> lyx2lyx script
> > failed to convert it. ""
> >
> > This is the message i got when i tried to open a Lyx file
> from an older
> > version 2.0.8.1 that i have been using and I have Ubuntu
> 14.0. This file is
> > extremely important to me as i have been working on it for 2
> years. I
> > desperately need help on opening up this file.
>
> Hi Kim,
>
> The first thing to do is to make a backup of the file. Opening and
> saving with newer versions could change something you don't want.
>
> Did you create the file using 2.0.8.1? Which version of LyX
> are you
> using now? How did you install that version? (e.g. from Ubuntu
> PPA?).
>
> There is no Ubuntu 14.0. Do you mean 16.4?
>
> Scott
>
>
>
>
>
> -- 
> John Kane
> Kingston ON Canada




Re: AMS Article: need Theorems, and SUBSECTIONS to share counter.

2017-10-03 Thread Richard Heck
On 10/03/2017 08:56 AM, rls wrote:
> I am Lyx beginner. Sorry if it's in the docs. Thanks in advance for
> your help.
>
> I need to have Theorems (and Lemmas, etc.) to share the same counter
> with subsectons.
>
> I can't find a way to do it with Lyx.
>
> === Example of Section 2, in a document 
>
>    2. Reals simply defined ...[Section 2 title here]
>
> 2.1. Recall ... [1st subsection here]
>
> 2.2. Lemma. Any 
>
> Proof. ...
>
> 2.3. Given f ... [2nd subsection here]
>
> 
> Before using Lyx, I would just use the preamble:
>
> \documentclass[12pt]{amsart}
> \usepackage{amsmath}
>
> \swapnumbers
> \theoremstyle{plain}
> \newtheorem{theorem}[subsection]{Theorem}
> \newtheorem{proposition}[subsection]{Proposition}
> \newtheorem{lemma}[subsection]{Lemma}
> \newtheorem{corollary}[subsection]{Corollary}
> \newtheorem*{theoremNoNum}{Theorem}
> .
> ---
> I could include in the Lyx Document > Settings > LaTex Preamble, some
> hack to identify the two counters, like:
> \makeatletter
> \let\c@subsection\c@thm
> \makeatother
>
> But then, the numbers displayed in the Lyx editor aren't what's printed.

The LyX display is controlled by 'layout' information, which is defined
in a number of places:

(i) The layout file for the document class (e.g., amsart.layout)
(ii) Modules, which are to LyX as packages are to LaTeX (e.g.,
theorems-ams.module)
(iii) Document-specific "local" layout, found at Document> Settings>
Local Layout

It seems to me as if you will probably be best off creating a new module
of your own, perhaps starting with and modifying theorems-ams.module.
Documentation concerning this is in Ch 5 of the Customization manual. As
far as the counters are concerned, you will want to modify the
LabelCounter defined for the various styles so that it uses the one for
subsections.

Note that you can just make modifications in Local Layout, e.g.:

Style Theorem
    LabelCounter subsection
    Preamble
        \theoremstyle{plain}
    \newtheorem{thm}[subsection]{\protect\theoremname}
    EndPreamable
End
Style Lemma
    LabelCounter subsection
    Preamble
        \theoremstyle{plain}
    \newtheorem{lem}[subsection]{\protect\theoremname}
    EndPreamable
End

Then you could just use the usual Theorems (AMS) module, and these
modifications might be enough to get you what you want. But if you are
going to want to re-use them, then putting them in a module of their own
will make that easier.

Richard




Re: "Date intended for the title?

2017-09-15 Thread Richard Heck
On 09/15/2017 01:58 PM, John Parejko wrote:
> I'm getting the following LyX error when building my project [1]
> (which has a custom class and layout[2]), both when outputting PDF or
> when exporting to LaTeX (XeTeX), although the created LaTeX and PDF
> appear to be fine:
>
>
> You are using at least one layout (Date) intended for the title, after
> using non-title layouts. This could lead to missing or incorrect output.
>
>
> I've defined Date, Title, Author, Abstract, and DocumentReference (a
> custom command) in the layout as "InPremable 1" (our LaTeX class
> expects them to come before \begin{document}), but still get the above
> message.

You need to define DocumentReference also as "InTitle 1". It might seem
as if InPreamble should do this automatically, but there are cases where
they come apart. Maybe "InPreamble 1" should by default imply "InTitle
1", but at the moment it doesn't.

Richard



Re: convert to rtf

2017-09-07 Thread Richard Heck
On 09/07/2017 08:02 AM, Patrick Dupre wrote:
> Hello,
>
> I have one machine with fedora 24 and one with fedora 26 (both with lyx 2.2.3)
> When I convert the lyx file to a rtf file, it works well on the 
> fedora 24 machine, and it does not work on the machine with 
> fedora 26.
> In both file .lyx/configure.log, I have the same:
> \converter latex  rtf"latex2rtf -p -S -o $$o $$i" "needaux"
>
> What should I check? I guess that the issue may be with the conversion from 
> the lyx to latex.

I wouldn't think so. If you're using 2.2.3 on both machines, then the
LaTeX output should be the same. The difference in the OS should not
make a difference. My guess would be that there may be a difference in
the latex2rtf converter.

If you run LyX from a terminal, you should see any error messages that
are output during the conversion. LyX just calls converters directly.

Richard



Re: Have you tested 2.3.0beta1?

2017-09-07 Thread Richard Heck
On 09/05/2017 07:25 PM, Scott Kostyshak wrote:
> I have not seen many bugs that have been reported regarding 2.3.0beta1.
> I would like to know whether this means that 2.3.0beta1 can be
> considered stable, which is what I believe, or whether it is just that
> not many people have tested it and that is why there have not been many
> bug reports.
>
> If you've tested, it would be useful if you just respond with e.g. "yes
> I briefly tested and didn't find any issues".

Hi, Scott,

I've been using master extensively over the last couple months, and
other than bugs I've reported I've had no problems at all. I actually
started doing it because I actually needed some of the new features,
e.g., biblatex support, some of the changes to the citation dialog,
inverted branches.

> If you're interested in testing, please back up all of your files.

Yes, we should all do that, but just in case

If any file from an earlier version of LyX is opened *and saved* with
any version of 2.3.0, then the original file will automatically be
backed up. The backup file will be found in the backup directory, if one
is set under Tools> Preferences> Paths, or else in the same folder as
the original file, if no backup directory is set. The filename of the
backup file will be:
ORIGNAME-lyxformat-NUM.lyx~
where NUM is the LyX format number of the original file. In the case of
2.2.x file, this will be 508, but in the case of older files it will be
different.

Scott, it might actually be a good idea to include this information in
the 2.3.0-ish announcements. People often ask what these files are, and
it's obviously good for people to konw they exist.

Richard




signature.asc
Description: OpenPGP digital signature


Re: Have you tested 2.3.0beta1?

2017-09-07 Thread Richard Heck
On 09/06/2017 02:08 AM, Anders Ekberg wrote:
> Tested briefly on Mac latest OS and fresh TeX installation. Only problem was 
> that the welcome document complains about unknown image format (svgz?)
> If that is ignored the document compiles fine except for that image, but it 
> should preferably be fixed.

I'm pretty sure this got reported earlier and was fixed recently.

Richard


>> 6 sep. 2017 kl. 01:25 skrev Scott Kostyshak :
>>
>> I have not seen many bugs that have been reported regarding 2.3.0beta1.
>> I would like to know whether this means that 2.3.0beta1 can be
>> considered stable, which is what I believe, or whether it is just that
>> not many people have tested it and that is why there have not been many
>> bug reports.
>>
>> If you've tested, it would be useful if you just respond with e.g. "yes
>> I briefly tested and didn't find any issues".
>>
>> If you're interested in testing, please back up all of your files.
>>
>> One useful way to test is to compile your current .lyx files. If you get
>> a LaTeX error where with a previous .lyx file you did not, then that
>> could be a bug.
>>
>> Thanks,
>>
>> Scott




Re: Have you tested 2.3.0beta1?

2017-09-07 Thread Richard Heck
On 09/05/2017 10:34 PM, Carlos Knauer wrote:
> Is there a version for Windows ? I am using version 2.2.3 and it works
> very well.

Yes, Windows binaries can be downloaded from
ftp://ftp.lyx.org/pub/lyx/devel/lyx-2.3/lyx-2.3.0beta1/
The one you want is the exe file.

Please note, as Scott said, that this is intended for testing. I've been
using it myself for actual work, but if you're not prepared to run into
difficulties, don't use it for that.

Richard

> Carlos, from Brasil
>
>
> On Tue, Sep 5, 2017 at 8:25 PM, Scott Kostyshak  > wrote:
>
> I have not seen many bugs that have been reported regarding
> 2.3.0beta1.
> I would like to know whether this means that 2.3.0beta1 can be
> considered stable, which is what I believe, or whether it is just that
> not many people have tested it and that is why there have not been
> many
> bug reports.
>
> If you've tested, it would be useful if you just respond with e.g.
> "yes
> I briefly tested and didn't find any issues".
>
> If you're interested in testing, please back up all of your files.
>
> One useful way to test is to compile your current .lyx files. If
> you get
> a LaTeX error where with a previous .lyx file you did not, then that
> could be a bug.
>
> Thanks,
>
> Scott
>
>



Re: "default" bibliography style in custom layout

2017-09-04 Thread Richard Heck
On 09/03/2017 07:36 PM, John K. Parejko wrote:
> Hello,
>
> I’m working with a custom LaTeX class[1], based off of article, and I’ve made 
> a LyX layout for it (attached below, modified from article.layout) that works 
> well so far, except for the bibliography. The latex class specifies the 
> bibliography style:
>
> \bibliographystyle{lsst_aa}
>
> and there is no option in LyX’s BibTeX Bibliography window to use the 
> “default” style, nor can I figure out a way to modify the custom layout file 
> to not insert \bibliographystyle. Thus, the document cannot be built because 
> there will be two styles.
>
> Is there a command to add to the layout file to prevent LyX from adding the 
> bibliography style? 

No, but you do not have to enter a style in the bibliography dialog. LyX
will insert one by default, but you can erase it. Then no
\bibliographystyle is output.

Richard



Re: LyX Cross-reference Label Default Content Inquiry

2017-08-28 Thread Richard Heck
On 08/28/2017 03:07 PM, Joel Kulesza wrote:
> Colleagues:
>
> Is there a mechanism for modifying how Insert -> Labels are
> automatically populated?  
>
> It appears to populate with the name of the associated entity, with
> spaces changed to dashes, up to a certain character limit.  
>
> Can this character limit be raised?  Can the space->dash conversion be
> modified?
>
> My ultimate goal is to provide more context in the labels themselves
> (mostly through NOT truncating them).  I usually just copy/paste the
> associated information of the default label; however, it would be
> convenient if something like this outcome could be made automatic. 
> That said, I'm glad the clickable UI element is truncated...

Short of modifying the source code, no, there's no way to customize
this. But you can of course patch the source for your own purposes if
you wish. The routine in question is Text::getPossibleLabel, in Text.cpp.

It probably would not be that hard to add preferences to control length
and what spaces get replaced with, though we're sometimes reluctant to
add too many preferences

Richard



Possible Bibliography Error [was Re: Error File '...lyx_tmpbuf0/Diss121.tex' was not closed properly.]

2017-08-27 Thread Richard Heck
On 08/27/2017 07:15 AM, Mark Hempelmann wrote:
> Dear Lyx-Wizards,
>
> I researched on above error and the closest I got was the discussion between 
> Wolfgang and Jürgen in 2010. However, my text compiled fine with Lyx 2.1.5, 
> now with the 2.2.3 update I get above error. I’m using German characters, 
> don’t know where to find the encoding, though, I thought it was Latin1 or 
> UTF8.
>
> I’m completely lost as where to start looking at, I cannot remove all my 
> „Umlaute“ or the like. I’m using bibdesk for literature. Here is my preamble:
>
>
> \usepackage[backend=biber,style=philosophy-modern,natbib=true]{biblatex}
> \usepackage{amsmath}
> \usepackage{amssymb}  % für mathbb
> \usepackage{marginnote}   % Randnotizen
> \usepackage{ragged2e}
> \usepackage{blindtext} % Lorem ipsum
> \usepackage{lipsum}
>
> \addbibresource{/Users/mhem23/Documents/Uni/Dissertation/Bibliothek/bibdesk/DissBib3.bib}
>
> \setlength{\marginparwidth}{2,5cm}% setze Randnotizbreite
> \renewcommand*{\marginfont}{\footnotesize \bfseries}
> \let\marginpar\marginnote % \marginpar ist jetzt identisch mit \marginnote
>
> \usepackage{xcolor}
> \usepackage[framemethod=tikz]{mdframed}   % für Absatzboxen aller Art
> \usepackage{longtable, array}
>
> Please help me along, it worked with my old Lyx!

Is this an error you are getting with all files, or just with one? Have
you looked at Tools> LaTeX Log to see what errors you might have gotten?
Another thing you can do is export the file to LaTeX and then run
pdflatex, etc, manually on it.

The error message you are seeing is likely misleading. There was a
change between 2.1.x and 2.2.x in how certain bibliography errors are
handled in LyX. They were previously (and wrongly) ignored. It may well
be that you are getting such errors now, and they are the actual
problem. But I can't remember the details. I'm changing the subject
header in the hopes of attracting such attention.

Richard



Re: Key binding of unicode-insert problem

2017-08-17 Thread Richard Heck
On 08/17/2017 03:04 PM, Shieh, Sanford wrote:
>
> I’m trying to bind unicode-insert of accents and umlauts on vowels
> using a bind file, and running into the following issue.
>
>  
>
> I have the following line in the bind file:
>
>  
>
> \bind   "M-S-: u" "unicode-insert 00FC" # umlaut lower u
>
>  
>
> But in the Preference Editing Shortcuts dialog box this shows up
> weirdly (also in attached JPEG)
>
>  
>
>  
>
> As this screenshot shows, there’s no problem when I use the dialog box
> to bind to the alt-shift-: followed by u combination.
>
>  
>
> Is this an issue with Win7, which I’m using? 
>

I also see something weird in the dialog, but it's a different weird
from yours. This is on Linux. My guess is that there is some kind of
font problem.

Can you file a bug about this at lyx.org/trac/?

Richard



Re: LyX native format stuck in the middle

2017-08-11 Thread Richard Heck
On 08/11/2017 04:23 AM, José Abílio Matos wrote:
>
> On Monday, 31 July 2017 18.30.31 WEST Steve Litt wrote:
>
> > I know what I'm asking for is monsterously difficult, and I know I
>
> > certainly don't have the technical chops to do it. But when it gets
>
> > done, LyX will be a brand new world, finally living up to its promise
>
> > of write once, deploy everywhere.
>
> >
>
> > Thanks,
>
> >
>
> > SteveT
>
>  
>
> The main technical problems of this enterprise are the math insets.
> Should they also be converted to an xml like format?
>

Personally, I don't think that would be necessary. There's no payoff for
doing that, so
far as I can see. Any more, say, than special encoding of the contents
of TeX Code.

Richard



Re: all-inclusive file format

2017-07-31 Thread Richard Heck
On 07/31/2017 08:31 AM, Helge Hafting wrote:
>
>
> Den 27. juli 2017 19:48, skrev Richard Heck:
>> On 07/27/2017 11:52 AM, Roberto wrote:
>>> Hi Richard, thanks for bringing in your experience.
>>>
>>> If the tar.gz was something you can "mount" like a read-write DMG it
>>> would make sense to say that the archive does what I have in mind. As
>>> far as I know one can open DMG files and edit them and close them,
>>> effectively saving the content. The way it is now with tar.gz for me
>>> it is good only for archival purposes.
>> In theory, this could probably be done using fusefs on Linux, but that's
>> not a general solution, and we don't automatically add images, say, to
>> the archive when you add a picture.
>
> Isn't fusefs overkill?

Yes, I was suggesting it only as a temporary solution.

> LyX does its work in a temp folder anyway.
>
> To support working with a single file containing a folder with
> file.lyx and several figures, just have LyX unpack that archive to the
> temp folder. Let the user edit the document. Since all the graphichs
> are unpacked too, they can be edited with their appropriate external
> editors if needed. When the author saves, LyX recreates the archive
> file and overwrites the original. (LyX knows this is a all-in-one
> document, because it was opened as such.) When LyX is closed, the temp
> directory goes away as usual.
>
> This should give us:
> * Backward compatibility.
>   - Those preferring figures as separate files see no change.
>   - Existing documents works as always
>
> * Those wanting an archive can "save as archive" (not export, but save).
>  - Then they get an archive containing the document and all included
> stuff. (graphics, subdocuments, external insets).  The original
> graphics files etc. must be kept - they may be in use for other
> purposes too. But no longer in use by the now archived document - it
> has its own copies of everything.
>  - To reverse the process, someone who opened an archive may use
> "File->convert to separate files". This replaces the archive file with
> the folder containing separate files.

This is precisely what I had in mind.

> Seems that this approach would fulfil Roberts wish for
> user-friendliness, without ruining things for the single-files crowd.
> LyX could mostly work "as usual", with the archiving code mostly
> dealing with "open" and "save". And of course, every graphic the user
> adds to a document while in archive mode.
>
> There is the question of what to do about inclusion of a graphic that
> exist higher up in the directory tree. I believe the user-friendly way
> would be to copy such things into the archive folder - possibly in a
> subfolder. 

Enrico's LyX archiver already solves this problem...somehow. It doesn't
matter a tremendous amount how, since the user won't actually see the
structure here, unless they manually unpack it.

Richard



Re: LyX truncates spacing in Local Layout and in Listings

2017-07-30 Thread Richard Heck
On 07/28/2017 05:21 AM, haim.ros...@gmail.com wrote:
>
> I noticed that whenever I enter contents to
>
> * Document -> Settings -> Local Layout
>
> * Document -> Settings -> Listings
>
> * Program Listings Inset -> Settings -> Advanced
>
> All the leading tabs are deleted by the validation. This disturbs the
> reading of this content. Is there any solution for this?
>

It works with spaces, but not with tabs. Same problem with the preamble,
actually.

JMarc, this seems to be because Lexer::getLongString trips leading tabs.
Is there an easy way around that?

> Another issue is that the tab stops are fairly far away from each
> other. I think that cutting them to two thirds is much better.
>

If we get tabs working, it will be easy to fix this. (Note to self:
tabstop width property = 40.)

Richard



Re: all-inclusive file format

2017-07-29 Thread Richard Heck
On 07/28/2017 07:47 PM, Dr Eberhard Lisse wrote:
> As an option, like "Compressed"?

Yes, precisely.

Richard


> On 2017-07-27 18:48 , Richard Heck wrote:
> [...
>> I'll think more about this. It's too late for 2.3, but it's something
>> that could go into 2.4.
>>
>> Richard
> [...]




Re: crash

2017-07-29 Thread Richard Heck
On 07/28/2017 04:57 PM, Patrick Dupre wrote:
> I still have this issue with version 2.2.3 (on fedora 26)

Unfortunately, this sort of crash report doesn't help us. With debug
symbols activated, we can't really tell anything from this backtrace. If
you could compile 2.2.3 yourself, and activate debug symbols, then that
would give us a much more useful crash report. Please also let us know
what you were doing when the crash occurred. It'd be even better if you
could figure out how reproduce it in a reliable way.

Richard


> (  1) lyx: lyx(+0x56d8dc) [0x560f21dbd8dc]
> (  2) lyx: lyx(+0x5d0ea6) [0x560f21e20ea6]
> (  3) lyx: lyx(+0x56c68e) [0x560f21dbc68e]
> (  4) lyx: lyx(+0x25ee38) [0x560f21aaee38]
> (  5) /lib64/libc.so.6: /lib64/libc.so.6(+0x366f0) [0x7f65176c06f0]
> (  6) lyx: lyx(+0x318fa6) [0x560f21b68fa6]
> (  7) lyx: lyx(+0x31a068) [0x560f21b6a068]
> (  8) lyx: lyx(+0x5465be) [0x560f21d965be]
> (  9) lyx: lyx(+0x488968) [0x560f21cd8968]
> ( 10) lyx: lyx(+0x318db0) [0x560f21b68db0]
> ( 11) lyx: lyx(+0x360ab0) [0x560f21bb0ab0]
> ( 12) lyx: lyx(+0x5c7f68) [0x560f21e17f68]
> ( 13) lyx: lyx(+0x5c3de1) [0x560f21e13de1]
> ( 14) /lib64/libQt5Core.so.5: QMetaObject::activate(QObject*, int, int, 
> void**)
> ( 15) /lib64/libQt5Widgets.so.5: QTabWidget::currentChanged(int)
> ( 16) /lib64/libQt5Widgets.so.5: /lib64/libQt5Widgets.so.5(+0x2f4e27) 
> [0x7f651915be27]
> ( 17) /lib64/libQt5Core.so.5: QMetaObject::activate(QObject*, int, int, 
> void**)
> ( 18) /lib64/libQt5Widgets.so.5: QTabBar::currentChanged(int)
> ( 19) /lib64/libQt5Widgets.so.5: QTabBar::setCurrentIndex(int)
> ( 20) lyx: lyx(+0x5c3f67) [0x560f21e13f67]
> ( 21) lyx: lyx(+0x5a10a7) [0x560f21df10a7]
> ( 22) lyx: lyx(+0x5a170f) [0x560f21df170f]
> ( 23) lyx: lyx(+0x5a1908) [0x560f21df1908]
> ( 24) lyx: lyx(+0x5a34e9) [0x560f21df34e9]
> ( 25) lyx: lyx(+0x57c2c7) [0x560f21dcc2c7]
> ( 26) lyx: lyx(+0x573ce0) [0x560f21dc3ce0]
> ( 27) lyx: lyx(+0x5feafd) [0x560f21e4eafd]
> ( 28) /lib64/libQt5Core.so.5: QMetaObject::activate(QObject*, int, int, 
> void**)
> ( 29) /lib64/libQt5Widgets.so.5: QAction::triggered(bool)
> ( 30) /lib64/libQt5Widgets.so.5: QAction::activate(QAction::ActionEvent)
> ( 31) /lib64/libQt5Widgets.so.5: /lib64/libQt5Widgets.so.5(+0x2c0424) 
> [0x7f6519127424]
> ( 32) /lib64/libQt5Widgets.so.5: /lib64/libQt5Widgets.so.5(+0x2c7e8b) 
> [0x7f651912ee8b]
> ( 33) /lib64/libQt5Widgets.so.5: QMenu::mouseReleaseEvent(QMouseEvent*)
> ( 34) /lib64/libQt5Widgets.so.5: QWidget::event(QEvent*)
> ( 35) /lib64/libQt5Widgets.so.5: QMenu::event(QEvent*)
> ( 36) /lib64/libQt5Widgets.so.5: QApplicationPrivate::notify_helper(QObject*, 
> QEvent*)
> ( 37) /lib64/libQt5Widgets.so.5: QApplication::notify(QObject*, QEvent*)
> ( 38) lyx: lyx(+0x57e3aa) [0x560f21dce3aa]
> ( 39) /lib64/libQt5Core.so.5: QCoreApplication::notifyInternal2(QObject*, 
> QEvent*)
> ( 40) /lib64/libQt5Widgets.so.5: 
> QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, 
> QWidget*, QWidget**, QPointer&, bool)
> ( 41) /lib64/libQt5Widgets.so.5: /lib64/libQt5Widgets.so.5(+0x1bc073) 
> [0x7f6519023073]
> ( 42) /lib64/libQt5Widgets.so.5: /lib64/libQt5Widgets.so.5(+0x1bea64) 
> [0x7f6519025a64]
> ( 43) /lib64/libQt5Widgets.so.5: QApplicationPrivate::notify_helper(QObject*, 
> QEvent*)
> ( 44) /lib64/libQt5Widgets.so.5: QApplication::notify(QObject*, QEvent*)
> ( 45) lyx: lyx(+0x57e3aa) [0x560f21dce3aa]
> ( 46) /lib64/libQt5Core.so.5: QCoreApplication::notifyInternal2(QObject*, 
> QEvent*)
> ( 47) /lib64/libQt5Gui.so.5: 
> QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*)
> ( 48) /lib64/libQt5Gui.so.5: 
> QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*)
> ( 49) /lib64/libQt5Gui.so.5: 
> QWindowSystemInterface::sendWindowSystemEvents(QFlags)
> ( 50) /lib64/libQt5XcbQpa.so.5: /lib64/libQt5XcbQpa.so.5(+0x6e7a0) 
> [0x7f650a2667a0]
> ( 51) /lib64/libglib-2.0.so.0: 
> /lib64/libglib-2.0.so.0(g_main_context_dispatch+0x157) [0x7f6519bd8247]
> ( 52) /lib64/libglib-2.0.so.0: /lib64/libglib-2.0.so.0(+0x4a5e8) 
> [0x7f6519bd85e8]
> ( 53) /lib64/libglib-2.0.so.0: 
> /lib64/libglib-2.0.so.0(g_main_context_iteration+0x2c) [0x7f6519bd867c]
> ( 54) /lib64/libQt5Core.so.5: 
> QEventDispatcherGlib::processEvents(QFlags)
> ( 55) /lib64/libQt5Core.so.5: 
> QEventLoop::exec(QFlags)
> ( 56) /lib64/libQt5Core.so.5: QCoreApplication::exec()
> ( 57) lyx: lyx(+0x266ed5) [0x560f21ab6ed5]
> ( 58) lyx: lyx(+0x11be66) [0x560f2196be66]
> ( 59) /lib64/libc.so.6: /lib64/libc.so.6(__libc_start_main+0xea) 
> [0x7f65176aa4da]
> ( 60) lyx: lyx(+0x12491a) [0x560f2197491a]
>
>
> ===
>  Patrick DUPRÉ | | email: pdu...@gmx.com
>  Laboratoire de Physico-Chimie de l'Atmosphère | |
>  Université du Littoral-Côte d'Opale   | |
>  Tel.  (33)-(0)3 28 23 76 12   | | Fax: 03 28 65 82 44
>  189A, avenue Maurice 

Re: all-inclusive file format

2017-07-27 Thread Richard Heck
On 07/27/2017 11:52 AM, Roberto wrote:
> Hi Richard, thanks for bringing in your experience.
>
> If the tar.gz was something you can "mount" like a read-write DMG it
> would make sense to say that the archive does what I have in mind. As
> far as I know one can open DMG files and edit them and close them,
> effectively saving the content. The way it is now with tar.gz for me
> it is good only for archival purposes.

In theory, this could probably be done using fusefs on Linux, but that's
not a general solution, and we don't automatically add images, say, to
the archive when you add a picture.

I'll think more about this. It's too late for 2.3, but it's something
that could go into 2.4.

Richard



>
> Hopefully more people would enjoy having a "all-inclusive" file like
> this one.
>
> Cheers,
> Roberto
>
>
> On 27/07/2017 16:40, Richard Heck wrote:
>> On 07/27/2017 09:07 AM, Roberto wrote:
>>> Let me explain better. The reason for asking for a feature like that is
>>> not that I cannot clic one more time to unpack a tar.gz :)
>>>
>>> The tar.gz is an export, not a "Save", that is the difference. Save
>>> means that you can edit it and keep saving every now and then.
>>>
>>> Furthermore the two things are difference because you can even remove
>>> the pictures from the disk and you still have them in the file.
>>>
>>> What I am looking for is a LyX file that does as a MS Word file does:
>>> one editable file contains all you need to work on the document.
>>>
>>> One could achieve this if the LyX file was actually a directory
>>> structure managed by LyX and when you save the file you save all the
>>> directory structure controlled by it. The user does not need to see
>>> all the complications about where the pictures are stored, just needs
>>> to see the pictures in the file.
>>
>> There was some discussion of such a file structure, and I did a bunch of
>> work on it myself a few years ago. But there were also disagreements
>> about how exactly it should work, so it never went anywhere. The archive
>> we have now was a kind of compromise. But note that it really is a
>> pretty good compromise. It gives you, precisely, a 'directory structure'
>> that contains all the files needed for that document. It's just that
>> it's packed into a zip file or whatever.
>>
>> What it LyX was able to open such an archive directly? And what if, when
>> it had done so, it 'saved' the file directly to such an archive? I can
>> easily imagine the unpacking actually being done into the temporary
>> directory. This might not be very hard to achieve.
>>
>> Richard
>>
>>
>
>



Re: all-inclusive file format

2017-07-27 Thread Richard Heck
On 07/27/2017 09:07 AM, Roberto wrote:
> Let me explain better. The reason for asking for a feature like that is
> not that I cannot clic one more time to unpack a tar.gz :)
>
> The tar.gz is an export, not a "Save", that is the difference. Save
> means that you can edit it and keep saving every now and then.
>
> Furthermore the two things are difference because you can even remove
> the pictures from the disk and you still have them in the file.
>
> What I am looking for is a LyX file that does as a MS Word file does:
> one editable file contains all you need to work on the document.
>
> One could achieve this if the LyX file was actually a directory
> structure managed by LyX and when you save the file you save all the
> directory structure controlled by it. The user does not need to see
> all the complications about where the pictures are stored, just needs
> to see the pictures in the file.

There was some discussion of such a file structure, and I did a bunch of
work on it myself a few years ago. But there were also disagreements
about how exactly it should work, so it never went anywhere. The archive
we have now was a kind of compromise. But note that it really is a
pretty good compromise. It gives you, precisely, a 'directory structure'
that contains all the files needed for that document. It's just that
it's packed into a zip file or whatever.

What it LyX was able to open such an archive directly? And what if, when
it had done so, it 'saved' the file directly to such an archive? I can
easily imagine the unpacking actually being done into the temporary
directory. This might not be very hard to achieve.

Richard



Re: cache

2017-07-16 Thread Richard Heck
On 07/16/2017 01:44 PM, Patrick Dupre wrote:
> Hello,
>
> The directory .lyx/cache
> contains numerous files with large size (eps, pdf).
> Is there a way to keep this directory a lot smaller ?

These are the results of image conversions, which LyX saves so it doesn't
have to do the conversion the next time you open the same file. There is, at
the moment, no mechanism in LyX itself to manage the size of this directory,
etc. But you can just erase all the files periodically if you wish to
clean it up.
They'll be re-generated the next time they are needed.

Richard



Re: Fwd: Local modules under Windows 10

2017-07-08 Thread Richard Heck
On 07/08/2017 03:51 AM, Murat Yildizoglu wrote:
> Sorry, I have done a direct reply in mys reply to Paul. Here it is for
> the list.
> -- Forwarded message --
> From: >
> Date: 2017-07-08 9:51 GMT+02:00
> Subject: RE: Local modules under Windows 10
> To: "Paul A. Rubin" >
>
>
> Thank you very much Paul pour this tip. The  ~/AppData/Roaming/Lyx22/
> is indeed thefolder indicated there. Its layouts subfolder is the
> initial folder in which I have put these module files, but LyX
> complains even after reconfigure and restart of Lyx  (I have even
> restarted Windows for good measure and reconfigured again Lyx, no
> success).
>
> I am really puzzled.
>

Is there an error in the module possibly? Perhaps LyX is failing to
parse it for some reason.

You might check the configure.log file that you will find in the user
directory and see if there are any clues there.

Richard



Re: Issues using lyx

2017-06-23 Thread Richard Heck
On 06/23/2017 12:05 PM, David L. Johnson wrote:
>
> There are, for some, disadvantages to linux as well: No Word (I regard
> this as a feature, not a problem), not many games.  

When needed for inter-operability, I find LibreOffice perfectly usable,
unless you need some advanced features of the latest Word.

Richard



Re: Issues using lyx

2017-06-23 Thread Richard Heck
On 06/23/2017 03:45 PM, Cris Fuhrman wrote:
>
>
> On Thu, Jun 22, 2017 at 10:12 PM, Mr William Balthes
>  > wrote:
>
> A suggestion from the list is that I use linux.
>
> I know nothing about it.  Does it have automatic updates that you
> can't avoid where the system restarts.
>
> I've not had any data loss on my Windows 10 due to automatic updates,
> but I tend to always save my files before going away from my PC. In
> defense of auto-updates as a Win10 mechanism, a power loss overnight
> would also put you at risk if you didn't save your LyX file properly
> and use a reliable backup system, even in linux. 
>
> Using a cloud file service, e.g., Dropbox or Google drive, etc. is a
> way to have a copy of your file in case something weird happens. I'm
> pretty sure that Google Drive has a way (albeit cryptic) to recover
> versions of the same file for up to 30 days.

I have found Spider Oak an excellent backup service, and I believe they
will do 10GB free.

Richard



Re: Is "Citation Style" menu tweakable?

2017-06-20 Thread Richard Heck
On 06/20/2017 06:25 PM, David Pesetsky wrote:
> Thank you for your detailed reply (and hello)!  Your suggestion to add
> "comma" to /[...]Class Options>Custom/ works very well, thank you!  
>
> But no matter what I put after \setcitestyle (or where I locate the
> command in the document -- preamble, body), I get an error message
> from Lyx — for example:
>
>> \setcitestyle
>> {notesep={: }}
>> The control sequence at the end of the top line
>> of your error message was never \def'ed. If you have
>> misspelled it (e.g., `\hobx'), type `I' and the correct
>> spelling (e.g., `I\hbox'). Otherwise just continue,
>> and I'll forget about whatever was undefined.
>
> It's not worth chasing down this problem to the ends of the earth, but
> if you have any troubleshooting suggestions, I'd be happy to try them.

Very odd. The \setcitestyle command is defined by natbib.sty, and you
said you were using natbib, yes?  (It did not exist before version 8 of
natbib, but that was about a decade ago.) What OS are you using? Do you
know what LaTeX distribution you have? Actually, maybe a better questin
is: What document class are you using?

If you could produce as small a file as possible that causes this to
happen and post that, then it will help debug the issue.

Richard



Re: Is "Citation Style" menu tweakable?

2017-06-19 Thread Richard Heck
On 06/19/2017 08:48 PM, David Pesetsky wrote:
> Is there a way to tweak Lyx so the Citation dialog shows a different set of 
> options for "Citation Style" than the ones that appear by default when I have 
> selected  "natbib" and "author-year" in Document Settings/Bibliography?  I'd 
> be interested in having a comma rather than semicolon separating multiple 
> references, for example.  
>
> There's nothing I can't produce manually, of course, by simply selecting the 
> date-only option on the Citation Style pull-down menu and typing what I want 
> before and after the date, but if I could take advantage of the pull-down 
> menu options more often, it would save some effort.
>
> Similarly, for some purposes, at least, I'd be happy if I could tweak "text 
> after" in the same dialog so that it ends up preceded by a colon rather than 
> the comma that Lyx inserts.

The issues you're raising here are actually LaTeX issues, rather than
LyX issues. It's important, in understanding how LyX operates, to
separate these: There's the question how things look in LyX; then there
is the question how the PDF looks when it is generated. The latter
ultimately concerns LaTeX. In some cases, LyX provides a 'native' way to
tweak the LaTeX output. But oftentimes, you have to do something
manually, e.g., add something to the LaTeX preamble.

In this case, the semi-colon citation-separator and comma before the
"text after" are being inserted by natbib, which is what formats the
citations and bibliogrpahy. So it's natbib that we need to control. The
natbib manual
http://mirror.utexas.edu/ctan/macros/latex/contrib/natbib/natbib.pdf
has a bunch of information about tweaks. Section 5 of the manual
mentions a number of package options that change global behavior. The
one you want for your first request is "comma". You just add this, as a
class option, under Document> Settings> Class Options> Custom. (If there
already are some there, this is a comma-separated list, so add it with a
new comma, e.g.: draft,comma.)

For the other one, section 2.9 of the natbib manual explains how to
select citation punctuation using the \setcitestyle command. In your
case, you want:
\setcitestyle{notesep={: }}
to select a colon followed by a space. It is probably easiest to put
this command into Document> Settings> LaTeX Preamble, though it can also
be entered as TeX code in the document itself. Note, by the way, that
natbib seems to be quite picky about space before and after the "=",
i.e., it does not like space there.

As it happens, \setcitestyle will also control the citation separator,
so you could just do:
\setcitestyle{notesep = {: },citesep={,}}
and skip the class option, if you wanted.

Note that this will NOT change how the citations appear within LyX
itself. That can be done, but it's a much messier matter.

Richard Heck

PS Yes, the Richard Heck from the other side of L



Re: Issue with Lyx Editor

2017-06-07 Thread Richard Heck
On 06/07/2017 10:51 AM, Alejandro Peralta Alzate wrote:
> Dear
> ​Lyx development group​
> ,
>
> I have an issue with LyX editor.
>
> But I want to know how to notify and where to post it
> ​?​
> .
>
> It's referent to menus. When I​ c​lick​ to an item, for example
> preferences of LyX (
> ​T​
> ools --> Preferences), and close the window of preference after
> configuring, appear like a phantom in the screen (See the image
> attached to this email)
> ​ and this "phantom" doesn't disappear from the screen.​
>
>
> ​I think is not necessary to install qt before installing Lyx, I don't
> know what happen.​

Presumably, the package manager does this for you.

> I installed the software on a Distro Linux Mint 17.3 Rosa 64 bits, and
> the version of TexLive is: 2017. The version of Lyx is: 2.2.2

Just so I understand. The problem is that one of LyX's menus just stays
there? Even though you are not using it?

If so, then that looks like a problem with Qt. LyX does not control
these sorts of menu actions by itself, but delegates them to Qt.

Richard



Re: Lyx/Latex Beamer Compatibility

2017-05-29 Thread Richard Heck
On 05/29/2017 08:55 PM, Christos Makridis wrote:
> Hey Lyx Community,
>
> One of my collaborators downloaded lyx, but for some reason it
> prevented her from compiling her latex files as she normally did.

Is this on Windows? Which version of LyX did she install? and how?

Richard



Re: LyX Layout File Problem

2017-05-24 Thread Richard Heck
On 05/21/2017 07:59 AM, km22 wrote:
> I am trying to load a custom LyX layout file but I get the following
> error when I try to set the Document Class for the document.  I have
> reconfigured many times and restarted LyX many time.  The error
> message reads as follows.  Is there a way to determine why exactly LyX
> is complaining about the layout file?
>
> Thanks,
> Ken
>
>
> Log messages:
>
> 19:48:56.710: Opening document ~\Documents\Projects\MyProjects\Test\My
> Test File v20170521.lyx...
>
> 19:48:56.754: The process failed to start. Either the invoked program
> is missing, or you may have insufficient permissions to invoke the
> program.D:\LyXGit\LyX22\src\support\Systemcall.cpp (260): Systemcall:
> 'git ls-files "My Test File v20170521.lyx"' did not start!
>
> D:\LyXGit\LyX22\src\support\Systemcall.cpp (261): error The process
> failed to start. Either the invoked program is missing, or you may
> have insufficient permissions to invoke the program.
>
> D:\LyXGit\LyX22\src\TextClass.cpp (345): Unable to convert
> C:/Users/Ken/AppData/Roaming/LyX2.2/layouts/lknote_test.layout to
> format 60
>
> Error reading `~\AppData\Roaming\LyX2.2\layouts\lknote_test.layout'
>
> (Check `lknote_test')
>
> Check your installation and try Options/Reconfigure...
>
> Error: Could not load class
>
> 
>
> Due to some error in it, the layout file:
>
> lknote_test
>
> could not be loaded. A default textclass with default
>
> layouts will be used. LyX will not be able to produce
>
> correct output.
>
> 19:48:58.746: Document ~\Documents\Projects\MyProjects\Test\My Test
> File v20170521.lyx opened.
>
> 19:48:58.751: (file-open
> C:/Users/Ken/Documents/Projects/MyProjects/Test/My Test File
> v20170521.lyx)
>
>
>
>
> I have created a minimal layout file as follows which causes the error
> above:
>
> #  \DeclareLaTeXClass[lknote_test,scheme_main.sty]{LK Note Test}
> #  \DeclareCategory{LKNote}
> # Input general definitions
> Input stdclass.inc
>
> Format 49

This is invalid. The format line *has* to be the first non-empty,
non-comment line.

As Philip mentioned, though, if this is for 2.2.x, you should use format
60, so no conversion is needed.

> ClassOptions
> Otherdevel
> end
>
> Preamble
>
> EndPreamble

You don't need those, if there's nothing in them.

That may be the only issue with the layout. The program that is failing
to start is git, which is a different issue.

Richard



Re: [ANNOUNCE] LyX 2.2.3 Released

2017-05-16 Thread Richard Heck
On 05/16/2017 12:33 PM, Davide Anchisi wrote:
> Hi,
>
> I cannot find any 2.2.3 release (neither tar.gz nor tar.xz) at
> ftp://ftp.lyx.org/pub/lyx/stable/2.2.x/
> It seems that 2.2.3 is available only from devel
> (ftp://ftp.lyx.org/pub/lyx/devel/2.2/  -- modified: May 08 2017)
>
> I'll wait, and thanks for this new release.

For some reason, the source files seem to have disappeared when I
uploaded the binaries. I'll fix it when I get home.

Richard



Re: [ANNOUNCE] LyX 2.2.3 Released

2017-05-16 Thread Richard Heck
On 05/16/2017 09:55 AM, Edwin Burmeister wrote:
> Thanks for your reply. Here are my answers:
>
> I am using LyX 2.2.3 running under OS 10.12.4.
>
> (1) “lists.lyx.org ” is highlighted in my
> MacMail. Clicking on it ordinarily should launch a new message in
> MacMail, but instead Safari starts and I get the error message “file
> does not exist.” Not serious, but strange.

The original email is just plain text. MacMail is highlighting it as a
link. Thunderbird does the same. I see it even in your email. This is
something those programs are doing: They think it's a URL (without an
explicit protocol, which they assume is http), so they highlight it.
It's not a URL, though, so they're just wrong in this case.

Richard



[ANNOUNCE] LyX 2.2.3 Released

2017-05-15 Thread Richard Heck
Public release of LyX version 2.2.3
===

We are proud to announce the release of LyX 2.2.3. This is the third
maintenance release in the 2.2.x series.

You can download LyX 2.2.3 from http://www.lyx.org/Download/.

LyX is a document processor that encourages an approach to writing based
on the structure of your documents and not simply their appearance. It is
released under a Free and Open Source Software license.

LyX 2.2.3 is the result of on-going efforts to make our stable version more
reliable and more stable. We have fixed a number of bugs and made a number
of improvements. Most of these are relatively minor in themselves, but
the combined result of fixing them all has led to significant
improvements. We encourage all users of 2.2.2 to upgrade to this version.

If you think you have found a bug in LyX 2.2.3, please open a bug report at
http://www.lyx.org/trac/wiki/BugTrackerHome. If you're not sure whether it
really is a bug, you can e-mail the LyX developers' mailing list (lyx-devel
 lists.lyx.org) and ask.

If you have trouble using LyX or have a question, consult the
documentation that comes with LyX and the LyX wiki, which lives at
http://wiki.lyx.org/. If you can't find the answer there, e-mail the LyX
users' list (lyx-users  lists.lyx.org).

We hope you enjoy using LyX 2.2.3.

The LyX team.
http://www.lyx.org


What's new
==

** Updates:
***

* DOCUMENT INPUT/OUTPUT

- Allow use of verbatim and quotation environments with IOP articles
  (bug 10505).

- Search for input files relative to local layout files, when those
  are provided and relative paths are used.


* USER INTERFACE

- The title bar is now set according to platform UI. Read-only and
  version control are shown by indicators in the status bar.

- The toolbar context menu and the View>Toobars menus are now
  identical. Both allow to change icon size and to enable individual
  toolbars.

- The citation dialog has been redesigned, following user suggestions.

- Remember citation style settings both within and between sessions
  (bug 10256).

- Improve cross-references dialog design.

- Implement wrap-around in change tracking's next-change function (bug
10388).

- The Math Delimiters dialog now has a "Swap & Reverse" button (bug 10457).

- Document Settings > "Output" has been renamed to "Formats" now that it
  also contains the option "Save transient properties".

- The title of the source pane now reflects the format being previewed,
  e.g. "LaTeX (pdflatex) Preview".

- Improve information preview of bibliographic references (e.g. in the
  Citation dialog), particularly for bibtex databases that use biblatex
  features.

- When using Return in an empty paragraph and the depth is reduced,
  the layout of the paragraph is now changed accordingly.

- Issue an error message if incompatible languages (in terms of language
  package requirements) are used (bug 10456).

- Improve display speed, especially when compiled against Qt 4.x.

- Polish the BibTeX add dialog (bug 9795).

- Fix regression that was not allowing inserting more than three consecutive
  dashes without jumping through hoops.


* DOCUMENTATION AND LOCALIZATION

- New Arabic translation of the Intro and Tutorial manuals and the Shortcuts
  documentation file

- Updated translation of the French EmbeddedObjects and UserGuide manuals

- Updated Arabic, Brazilian, Chinese, German, Italian, Slovakian, Swedish,
  Ukrainian and French user interface localization.


* BUILD/INSTALLATION

- Correctly determine whether the X11 backend is used by Qt 5.8.


** Bug fixes:
*

* DOCUMENT INPUT/OUTPUT

- Fix nested language handling with polyglossia (bug 9633).

- Fix usage of multiple varieties of the same polyglossia language.

- Fix LaTeX output of fixed-width cells with decimal separator (bug 9568).

- Fix strike out of deleted display math with track-changes and pdf
  output (bug 9678).

- Do not hardcode required packages for Note inset.

- Make *-lyxformat-* backup files use .lyx~ extension.

- Quote filenames used for forward-search with SumatraPDF (bug 10342).

- The '|' special character in index insets must no longer be inserted via
  TeX-mode.

- Fix preview of language switching commands for single paragraphs in some
  corner cases.

- Show symbol name and description in plaintext export of nomenclature
  entries (bug 10459).

- Correct encoding for Baltic languages like Lithuanian (bug 10474).

- Fix some quote inset bugs (bug 10451):
  # Adjoining closing Single + double quote becomes double + single quote
(for English, Swedish and German).
  # French double quotes are converted to << >> in the LaTeX file and to
double inverted question/interrogation marks in the output, if the font
encoding is set to [None] or OT1 but the global default is T1.
  # Quote type ignored for LyXHTML: always "English" quotes used.

- Output correct identifier for DocBook XML.

- Correctly escape hyperlinks for DocBook 

Re: Help needed in the use of LyX

2017-05-10 Thread Richard Heck
On 05/10/2017 12:35 PM, PhilipPirrip wrote:
> On 05/10/2017 12:23 PM, Jürgen Spitzmüller wrote:
>> Which is achieved in LyX by inserting a footnote in the author
>> paragraph.
>
> Thanks Jürgen, good to know.
> But... Why was such an unintuitive, easter-egg-like choice made?

The \thanks command really is a sort of footnote command:

\long\def\thanks#1{\footnotemark
\protected@xdef\@thanks{\@thanks
\protect\footnotetext[\the\c@footnote]{\@IEEEcompsoconly{\itshape
\protect\@IEEEtriggeroneshotfootnoterule\relax}\ignorespaces#1}}}

so that's probably why. Of course, that doesn't make it transparent to
new users what to do,
though it is illustrated in the template, I believe.

Richard



Re: Web page not working?

2017-05-08 Thread Richard Heck
On 05/08/2017 09:11 AM, Elena Luna Garcia wrote:
> Hello,
>
> I would like to download the latest version of LyX. but the web page seems to 
> be down. Could you help me to obtain the installer for Mac OS? Do you know 
> when is going to be the site available again? 

There is some problem, we think caused by bots scraping the site, that
occasionally causes LyX's web server to go down, or become so slow it
seems like it is down.

But you do not need to go through that to get the latest version. Just
go here:
ftp://ftp.lyx.org/pub/lyx/bin/2.2.2/
and download what you need.

Richard

PS LyX 2.2.3 should be out within a week or so.



Re: No print icon in Debian Stretch lyx 2.2.2

2017-05-04 Thread Richard Heck
On 05/03/2017 07:51 PM, Paul A. Rubin wrote:
> On 05/03/2017 07:42 PM, John White wrote:
>> On Tuesday, May 2, 2017 10:52:53 AM PDT John White wrote:
>>> I upgraded from Jessie to Stretch and now there is no print icon in
>>> lyx.
>>> Cntrl-d brings up xdvik and renders a dvi file.  Pushing cntrl-P in
>>> xdvik
>>> says it prints, but it doesn't.   So I have to export to pdf to print.
>>>
>>> Any suggestions as to how I might get a print option in lyx?
>>>
>>> John
>> I got xdvki/dvi to print fine (my alert IT guy added a missing
>> dependency), so
>> only question now is:  what happened to the print icon in lyx?  It
>> used to be
>> in the "File" dropdown menu.  Its no huge deal as now to print I
>> press cntrl-d
>> and then cntrl-p, instead of just cntrl-p as before, but it still seems
>> strange that there is no print icon in my lyx 2.2.2.
>>
>>
>>
> I believe Richard Heck answered this (but I've deleted my copy of the
> message). IIRC, he said that direct printing had been removed from LyX
> due to a combination of very few people using it and it being a PITA
> for the devs. 

One problem was that it had a ton of options that, again, seemed rarely
to be used. In a way, the more serious problem was that it was tightly
tied to DVI, so no PDF-specific features could be used.

> Personally, I never used it and never noticed it was gone. The
> "official" way to print now is to compile and view the document (which
> ctrl-D in LyX does for you) and then print it from the viewer (which
> ctrl-P apparently does in xdvik).

As I also mentioned, it's possible to restore printing, in a way, if one
wants to do so. The short version is:
1. Use Tools> Preferences> File Handling> File Formats to create a
new "Print" format.
2. Use Tools> Preferences> File Handling> Converters to define a new
(say) DVI --> Print converter. Define the converter as whatever command
line you might use to print. You can define a shortcut for this now if
you like.

Richard



Re: No print icon in Debian Stretch lyx 2.2.2

2017-05-02 Thread Richard Heck
On 05/02/2017 01:52 PM, John White wrote:
> I upgraded from Jessie to Stretch and now there is no print icon in lyx.  
> Cntrl-d brings up xdvik and renders a dvi file.  Pushing cntrl-P in xdvik 
> says it prints, but it doesn't.   So I have to export to pdf to print.
>
> Any suggestions as to how I might get a print option in lyx?

I am not sure why printing from xdvik doesn't work. But printing from
within LyX was removed for 2.2.0. Very few people used it, and it was
complicated to maintain. So you do now have at least to 'view' the file
to print it. But you shouldn't have to export it.

It is possible to add 'printer' as an export format. I posted a message
about that to the users list some time back.

Richard



Re: Single Column Indices

2017-04-28 Thread Richard Heck
On 04/28/2017 12:50 PM, Karthik Tayur wrote:
>
> I resolved this by using the idxlayout package. What would be the use
> case for the "options" space in the indexing tab under Document
> Settings? Just curious.
>
> \usepackage[columns=1]{idxlayout}
>

If using makeindex, say, as the processor, then one could add -g to use
German word ordering, or -s FILE to specify an index style file, or
whatever. I.e., these are options to makeindex, for which see "man
makeindex". Same for xindy, or whatever.

Richard


>
> On 27 April 2017 at 09:37, Karthik Tayur  > wrote:
>
> Hi,
> How does one obtain single column indices? This question has been
> raised before as regards LaTeX. How does one do it with LyX?
> Since the default processor appears to be xindy from the
> documentation, I will need to modify the relevant style?
>
> Regards
> K
>
>



Re: Index does not print

2017-04-28 Thread Richard Heck
On 04/28/2017 09:30 AM, Karthik Tayur wrote:
> Appears to be an encoding related problem. I had pasted some text into
> LyX. ChkTeX failed. Running iconv to obtain UTF-8 started displaying
> the index again. Thanks to some of the mails on this thread which
> mentioned encoding related problems.
> Since copy pasting is a routine activity, isn't there any way of
> addressing this? Plus, LyX not giving any indication of this problem
> makes it difficult for novice users.

Can you please file a bug report about this at
https://www.lyx.org/trac/wiki/BugTrackerHome
You will need to register first, if you haven't.

I agree it is a problem, but I've leanred enough about encodings to know
that dealing with them is difficult. If one has a file (or string), it
can be difficult to tell what the encoding is. But we should perhaps do
something when we cut and paste into LyX to try to make sure we have UTF-8.

Richard


>
> On 27 April 2017 at 09:25, Karthik Tayur <karthiksta...@gmail.com
> <mailto:karthiksta...@gmail.com>> wrote:
>
> Sorry for the delayed reply.
> I tried to replicate the problem in a file as small as possible
> (as suggested). I couldn't reproduce it.
> On that note, for some reason, I had encoding problems with the
> same .lyx document. I used iconv to resolve that problem.
>
>
>
> On 25 April 2017 at 18:40, Richard Heck <rgh...@lyx.org
> <mailto:rgh...@lyx.org>> wrote:
>
> On 04/24/2017 11:41 PM, Karthik Tayur wrote:
>> Replacing all special characters (Insert>Symbols) in the
>> document allows me to print the indices. I had inserted the
>> pilcrow symbol in the document. When resolving a problem with
>> conversion I replaced all the symbols in my document with text.
>> Any idea why this works? Are special symbols not allowed in
>> footnote spaces?
>
> If you could produce a small file, as small as possible, that
> illustrates the problem, it would make it easier to
> investigate. The reason it should be small is so we can be
> sure where the problem really is.
>
> Richard
>
>
>>
>>
>> On 25 April 2017 at 03:42, Karthik Tayur
>> <karthiksta...@gmail.com <mailto:karthiksta...@gmail.com>> wrote:
>>
>> Hello,
>> I have been using LyX for some time now. It has been
>> great. Previously the multiple index function worked well.
>> Today, while I was able to insert indices, they wouldn't
>> print. Only disabling the multiple index option under
>> Settings in a fresh document allows printing of the
>> singular index.
>> Any suggestions as to how I might go about solving this
>> problem? I suspect that the files needed for \printindex
>> simply don't compile, as the logs seem to suggest.
>>
>> System Details: Arch Linux with KDE, LyX 2.2.2
>>
>> Regards
>>
>>
>
>
>



Re: LyX 2.3 alpha nomenclature

2017-04-26 Thread Richard Heck
On 04/26/2017 06:31 AM, F M Salter wrote:
>
> Nomenclature entries produce pdf showing  $x$ not /x!/
>

It would be helpful if you could produce a small (minimal) test file.
It would also be best sent to lyx-devel (cc'd here).

Richard



Re: Index does not print

2017-04-25 Thread Richard Heck
On 04/24/2017 11:41 PM, Karthik Tayur wrote:
> Replacing all special characters (Insert>Symbols) in the document
> allows me to print the indices. I had inserted the pilcrow symbol in
> the document. When resolving a problem with conversion I replaced all
> the symbols in my document with text.
> Any idea why this works? Are special symbols not allowed in footnote
> spaces?

If you could produce a small file, as small as possible, that
illustrates the problem, it would make it easier to investigate. The
reason it should be small is so we can be sure where the problem really is.

Richard


>
>
> On 25 April 2017 at 03:42, Karthik Tayur  > wrote:
>
> Hello,
> I have been using LyX for some time now. It has been great.
> Previously the multiple index function worked well.
> Today, while I was able to insert indices, they wouldn't print.
> Only disabling the multiple index option under Settings in a fresh
> document allows printing of the singular index.
> Any suggestions as to how I might go about solving this problem? I
> suspect that the files needed for \printindex simply don't
> compile, as the logs seem to suggest.
>
> System Details: Arch Linux with KDE, LyX 2.2.2
>
> Regards
>
>



LyX and HiDPI Under Linux

2017-04-20 Thread Richard Heck
I'm thinking about buying one of these:

https://system76.com/laptops/galago

But it has HiDPI, and I'm curious what people's experience is using LyX
with HiDPI screens under Linux (KDE, in my case). Help?

Richard




Re: mailmerge

2017-03-31 Thread Richard Heck
On 03/31/2017 04:05 PM, John White wrote:
>
> I use lyx and am using it more and more in what I call "mailmerge"
> mode, similar to how I once used mailmerge in Wordstar. Once I have a
> good form document (say a will or a contract) I replace the names
> with, say "@name1" and then I replace all @name1 with the new data,
> e.g. "Judy Jones".
>
>  
>
> This works fine, but on longer documents (say a 40 page document)
> with, say @name1 through @name12, it can get a bit confusing. I put
> all the replacement data in a separate lyx file and go back and forth
> to that file until I have made all replacements.
>
>  
>
> I use article class.
>
>  
>
> Is there perhaps a better layout or class or perhaps something else
> lyx that I should be using?
>

The easiest way to do this would be to use some LaTeX in your LyX
document. Where you now have "@name1" put, say:
\nameone
in ERT. Now in the preamble, say, put:
\def\nameone{Judy Jones}
This is a LaTeX variable, or "macro".

You could also do something like:
\def\nameonef{Judy}
\def\nameonel{Jones}
\def\nameone{\nameonef \nameonel}
and now you have access to first, last, and full names.

You can also put all of that in some separate LyX file, if you like, but
as ERT, and include it at the beginning of the file.

Caveats:

LaTeX does not allow numbers in variable names, only letters (well,
close enough). Hence "one".

You'll have to be careful to avoid naming conflicts with what LaTeX
already predefines. One way to do this is to use names like, e.g.,
\MERGEnameone.

You may run into problems with spaces after such macros. This is because
LaTeX sees the space after the macro as just separating it from what
follows, not as an actual space. You can handle this in a couple ways.
First, in the LyX file, you can do:
\nameone{}
in ERT. Now the braces terminate the macro, and LaTeX will treat a
following space as an actual space. The other option is to use the
xspace package. So the macro gets defined as:
\def\nameone{Judy Jones\xspace}
and you put
\usepackage{xspace}
into the preamble. The \xspace macro adds a space, but only if what
follows isn't punctuation, etc. It isn't perfect, but it usually works.

This is a very simple approach. Try searching "latex mail merge" for
more sophisticated ones.

Richard



Re: NatBib "sort" specifier

2017-03-31 Thread Richard Heck
On 03/31/2017 03:27 PM, Joel Kulesza wrote:
> All,
>
> Am I overlooking how to specify "sort
> "
> when using natbib via LyX?  I see how I can use it in the preamble,
> but I cannot find where to specify it using the Bibliography interface.

For now, add it as a document class option. It will be passed down the line.

> It looks like it should be specified as a \usepackage option. 
> However, in the Document -> Settings -> Bibliography window, it's not
> clear how I'd specify this.  I think this dialog is under active
> development; maybe this has been added?

In 2.3, there will be a place uneer Documents> Settings> Bibliography to
put such options.

Richard



Re: QUESTION & A REQUEST

2017-03-23 Thread Richard Heck
On 03/22/2017 02:25 PM, Bozdogan, Hamparsum (Ham) wrote:
> I have installed LyX on my new PC laptop Win 10 system. This is the
> new version 222.When I use the equation editor and the superscript for
> minus (-) sign it gives me left-upward arrow. Do you know why this is
> caused?

Are you sure you are using superscript? I get that symbol if I use the
script *font* and try to type a minus. How are you getting the superscript?

Richard



Re: LyX layout color customization

2017-03-21 Thread Richard Heck
On 03/21/2017 04:23 PM, Richard Heck wrote:
> On 03/20/2017 06:59 AM, Csaba Pusztai wrote:
>> Hi,
>>
>> Based on the documentation (Customizing Lyx: Features for the
>> Advanced User), only a handful of pre-defined colors are available
>> for use in layout files. The color of some elements are flexibly
>> changeable (full RGB), but in style declarations only the named
>> colors are available. Is there any way to work around that? If
>> nothing else, could I somehow re-define the named colours?
>
> I'm not sure what the answer to this is. Let me have a look and get
> back to you.

I've had a look at the code, and no, there's no way to define custom
colors. You can't even use the so-called "LyX colors", which can be
customized through Tools> Preferences> Colors and are listed in appendix
B of the Customization manual. At least, you can't use them for font
colors (though I think you can use them for inset backgrounds(.

I'd encourage you to file an enhancement request about this. At the
moment, there is no easy way to permit the definition and use of custom
colors. But maybe someone would want to take on the challenge of
generalizing this code.

Richard



Re: LyX layout color customization

2017-03-21 Thread Richard Heck
On 03/20/2017 06:59 AM, Csaba Pusztai wrote:
> Hi,
>
> Based on the documentation (Customizing Lyx: Features for the Advanced
> User), only a handful of pre-defined colors are available for use in
> layout files. The color of some elements are flexibly changeable (full
> RGB), but in style declarations only the named colors are available.
> Is there any way to work around that? If nothing else, could I somehow
> re-define the named colours?

I'm not sure what the answer to this is. Let me have a look and get back
to you.

Richard



Re: beamer flex frame options

2017-03-06 Thread Richard Heck
On 03/06/2017 10:12 AM, Neal Becker wrote:
> Neal Becker wrote:
>
>> Guillaume Munch wrote:
>>
>>> Le 06/03/2017 à 14:16, Neal Becker a écrit :
 I'm trying beamer(flex insets) document option.  I like it, but I don't
 see any way to set frame options.  Any hints?
>>> Insert > Frame options ?
>> AFAICT, if you choose beamer(flex inserts) for document, then there is no
>> menu item "(Insert > Frame options)".  This only appears if you choose
>> "beamer" for document.

You need to use the flex insets with the beamer document class.
(Unfortunately, there is no way at present to enforce this requirement.)

Richard



Re: Alt+M opens Mathematical Spacing menu

2017-02-24 Thread Richard Heck
On 02/24/2017 12:56 PM, Scott Kostyshak wrote:
> On Fri, Feb 24, 2017 at 08:39:04AM +0100, CieMaKat . wrote:
>> Hi,
>>
>> Thank you for the response.
>> I'm running v2.2.2.
>>
>> You said it's known bug - can I do something to get rid of it or is it up
>> to KDE developers?
> See here:
> http://www.lyx.org/trac/ticket/10261
>
> In particular, see comment 16 for a workaround:
> http://www.lyx.org/trac/ticket/10261#comment:16

And, for the record, the fix should be in 2.2.3.

I'd forgotten I'd held it back from 2.2.2, since it seemed so risky. I'm
glad it's
not a new incarnation of the bug.

Richard




Re: Alt+M opens Mathematical Spacing menu

2017-02-23 Thread Richard Heck
On 02/23/2017 03:49 PM, CieMaKat . wrote:
> Hello everyone!
>
> I decided to change my OS to Manjaro KDE (17.0-rc1) and use Lyx as I
> used to. But there's a problem - when I am in math mode and press
> [Alt]+[M] (to combine it with another key) the mathematical spacing
> menu shows up. That makes impossible to use most of mathematical
> shortcuts.
>
> There's an image what happens right after pressing [Alt]+[M]:
>
>
> What should I do?

This sounds like a KDE bug we saw a while ago. What version of LyX do
you have?

Richard



Re: how to reconfigure the style of on page ?

2017-02-19 Thread Richard Heck
On 02/19/2017 03:50 AM, subaochen wrote:
> hi,
>
> I want to redefine the cite style of " on page " to
> " on  page", but how?

This uses the \vref command from the varioref package, so see its
documentation. (I don't know how to do this myself.)

Richard



Re: foot note symbol in author listing

2017-02-13 Thread Richard Heck
On 02/12/2017 06:26 PM, Bob Alvarez wrote:
> I want to include my institution and email address in a footnote to my
> name on the first page of the article. I did this by inserting a
> footnote from the menu on Lyx.
>
> According to the User's Manual:
> The footnote will appear in the output as a superscript number at the
> text position where the footnote box is placed.
>
> A preview (and exporting the pdf output) of lyx file included below
> shows that the footnote appears but there is no footnote symbol after
> my name.
>
> I would like to have a symbol to draw the reader's attention to the
> information.
>
> Ideas on how to do this?

This is handled by the document class. You are using IEEEtran, and it
has decided that footnotes within the title information don't have
corresponding marks. So, if you don't like that behavior, you should try
a different document class. If, on the other hand, you really do need to
use IEEEtran, then, well, that is how the IEEE says it should be.

Richard



Re: Attaching References

2017-01-26 Thread Richard Heck
On 01/26/2017 01:42 AM, William Hanson wrote:
> Chris,
> I'm using Windows and LyX 2.0.5.1.  Since I've been unable to make LyX
> 2.2.2.2 work (more about that later), and since all I needed to do to
> complete my document was add three references, I tried to make 2.0.5.1
> do that for me. 
>
> However, since I first wrote the situation has changed somewhat.  (I
> suppose that's due to the messing around I've been doing.) 
>
> I do indeed have a BibTeX Generated Bibliography box at the end of my
> document.   And when I click on it the window that opens contains a
> link to the .bib file I created with Mendeley.  This sounds promising,
> but now when I try to insert a reference into the document (by
> choosing Citation) the box that pops up is empty. 

The most likely problem here is an encoding issue. I expect there is
some Unicode character in the Mendeley-generated bibfile that LyX is
choking on. My suggestion would to try bisecting the file to find the
offending character. First, make a backup of it in case something goes
wrong. Then open the file in Notepad or something and delete the last
half of it. Now see if it works in LyX. If so, the problem is in the
last half, so delete half of that, etc. If it doesn't work, delete more
of it, until you get something that does work.

Alternatively, if you want to send me the bib file (use this email), I
can look at it and see what the problem might be. Feel free to send me
the LyX file that isn't working, too. It may again be some kind of
encoding issue.

Richard



Re: Attaching References

2017-01-25 Thread Richard Heck
> On 25 Jan 2017, at 3:16 PM, William Hanson  wrote:
>> I'm using LyX 2.0.5.1, which I've used for years.  I've downloaded 2.2.2.2, 
>> but but I can barely get started with it.  It keeps telling me that I have 
>> to add new files to make things work, but I'm unable to do so, and the Users 
>> Manual doesn't help.

When is LyX 2.2.2 telling you that you need to add new files? What files
is it telling you that you need to add?

Richard



Re: opening the same file in two different tabs

2017-01-24 Thread Richard Heck
On 01/24/2017 05:24 PM, Julien SCORDIA wrote:
> Hello,
>
> Usually I edit a large document by splitting the view horizontally.
> However I would like to open the document in two different tabs. When
> opening an already open file, LyX only switches to the tab of this
> file. Is this possible to change this behavior so as to open the file
> in as many tabs as wanted?

Probably, so feel free to file an enhancement request. But what you can
do, for now (what I do), is do File> New Window, then open the file in
the new window.

Richard



Re: lyxHTML format problem

2017-01-20 Thread Richard Heck
On 01/20/2017 05:33 AM, subaochen wrote:
> yes, I guess the problem is just LyX's(version2.2.2) LyXHTML export.

I have just downloaded your file test.lyx and run it through the 2.2.0
export
and the 2.2.3dev export (current stable branch). Here's the diff:

/home/rgheck/> diff -u test20.xhtml test22.xhtml  
--- test20.xhtml2017-01-20 11:10:00.701373061 -0500
+++ test22.xhtml2017-01-20 11:02:12.417334595 -0500
@@ -2,7 +2,7 @@
http://www.w3.org/Math
/DTD/mathml2/xhtml-math11-f.dtd">
http://www.w3.org/1999/xhtml;>

-
+

test post with lyx 2.2.0

@@ -20,7 +20,7 @@
 


-
+
test post with lyx 2.2.0
first line,first line

Is something in your lyxblogger script sensitive to this change?

Richard



> 发自我的小米手机
> 在 Scott Kostyshak ,2017年1月19日 23:50写道:
>
> On Thu, Jan 19, 2017 at 05:39:10PM +0800, subaochen wrote:
> > Hi,
> >
> >
> > The mini example is test.lyx, and lyxhtml file is test.xhtml.
> >
> >
> > How to  reproduce the problem:
> > 1, install lyxblogger from:
> https://github.com/jackdesert/lyxblogger, very easy, just go to
> INSTALL directory and run: python setup.py 
> install . If any problem , you can also checkout from
> https://github.com/subaochen/lyxblogger, maybe I have corrected
> the missing file problem.
> > 2, install lyx 2.2.2, and run: python -m lyxblogger test.xhtml
> > 3, in the next xterm window, fill below information( the host is
> just for lyx test, so feel free to ):
> >- username: lyxtestc
> >- password: 12345678
> >- host: lyxtest.cloudaccess.host
> > 4 visit http://lyxtest.cloudaccess.host to see how the new post
> appears.
> > 5, install lyx 2.2.0, generate test.xhtml from test.lyx again.
> > 6 run python -m lyxblogger test.xhtml and post the test.xhtml to
> test site as a new post.
> > 7 visit  http://lyxtest.cloudaccess.host again to see how the
> new post appears, especially difference between lyx 2.2.2 and lyx
> 2.2.0.
> >
> >
> > My test result:
> > http://lyxtest.cloudaccess.host/?p=5 is the post by lyx 2.2.0,
> and  http://lyxtest.cloudaccess.host/?p=11  is the post by lyx 2.2.2.
>
> Thanks for these detailed instructions. Can you reduce the problem to
> just LyX's LyXHTML export? I guess we could look at the differences
> between 2.2.0 and 2.2.2 and go from there.
>
> Scott
> [attachment]
>
> signature.asc
> download: http://u.163.com/t0/ie65xSEfC1k
>
> preview: http://u.163.com/t0/z71fqwyDKF
>
>



Re: Problem using titling package with LyX 2.2.2

2017-01-16 Thread Richard Heck
On 01/08/2017 10:41 PM, Shieh, Sanford wrote:
>
> Attached titling-LyX-problem.lyx generates an error, ScreenShot of
> LaTeX error in LyX.jpg attached.  Also attached are the error log:
> titling-LyX-problem (LyX run).log, and the PDF output,
> titling-LyX-problem (LyX output).pdf.
>
>  
>
> Export to plain latex--- titling-LyX-problem.tex ---compiles in
> TeXnicCenter with no problems.  Attached are the .tex, .blg, .bbl,
> .log, .aux files and the PDF output.
>

I get the same error when compiling from the command line. This is both
with the tex file you attached and one I exported myself from your LyX
file. It looks to me as if titling.sty does not play nice with \RaggedRight.

Richard



Re: Searchable PDF documents

2017-01-14 Thread Richard Heck
On 01/14/2017 10:57 AM, Rich Shepard wrote:
> On Sat, 14 Jan 2017, Uwe Ade wrote:
>
>> For the preparation of my lecture notes I use Lyx and latex. Students
>> will
>> receive a PDF document for the lecture. However, the PDF documents
>> produced are not searchable for texts in the document. Can I create Lyx,
>> Beamer and Latex searchable pdFs? What is to be observed?
>
>   Can they use pdfgrep ? It works well for me (on
> linux) but may not be available for all platforms.

This is puzzling to me. All the PDFs I produce using LyX are searchable.
Though
I notice that, with Beamer, the headers are not searchable, though the
text is.

Richard



Re: Layout Style: Display as Uppercase?

2017-01-06 Thread Richard Heck
On 12/08/2016 12:24 AM, Joel Kulesza wrote:
> On Wed, Dec 7, 2016 at 3:42 PM, Scott Kostyshak  > wrote:
>
> On Wed, Dec 07, 2016 at 02:32:00PM -0700, Joel Kulesza wrote:
> > Colleagues:
> >
> > Is there a way to adjust the Font of a Style in a .layout to
> display as
> > UPPERCASE in LyX?
> >
> > I cannot see a way to do this in Help -> Customization --- have I
> > overlooked something?
> >
> > I am trying to get LyX to match the appearance of an associated
> .cls file
> > which converts all \section{...} entries to uppercase in the
> document.
>
> The feature does not currently exist. I have come across the same
> issue
> in the past. I think that there are conceptual issues and it is not
> clear we want to implement it. See the ticket here:
> http://www.lyx.org/trac/ticket/9489
> 
> If you can respond to the concern there then maybe it would be
> reconsidered.
>
>
> Thank you for confirming that the ability is absent and for pointing
> me to that ticket.  Indeed, I understand the point raised that
> representing non-uppercase text as uppercase would be misleading.  It
> would go against WYSIWYM.  However, one might approach WYSIWYM from
> two directions: that of the user and that of the publisher.  I believe
> the ticket to be written from the perspective of the user and his/her
> interaction with LyX (if they mean for uppercase, they should use/see it).

Another option, which we do sometimes use, is to change the color, as a
signal that something is weird. We do this, for example, with 'resumed'
enumerations, where the numbering ends up being wrong. So, e.g., we
could make the captialized section heading blue.

> To avoid the "loss of information" cited in the ticket, I would
> propose converting the case to uppercase as the section heading is
> typed so that any subsequent copy/paste would be uppercase.

Possible but would involve complicated hard-coding of this conversion,
and it would be very different from what else we do.

Richard



Re: LyX Spell Checker Sanity Check

2017-01-06 Thread Richard Heck
On 01/06/2017 03:08 PM, Joel Kulesza wrote:
> Colleagues,
>
> Does anyone know what "baed" means?  With all lower case, I cannot
> find any reasonable definition. 
>
> However, the spell checker (dialog and interactive) in LyX doesn't
> flag it as misspelled (though it's a case of me wanting to type
> "based").  
>
> I am using LyX 2.2.2 on OS X 10.11.6 with the as-distributed spell
> checker.  Is different behavior observed on other OSs and/or spell
> checkers?

The spell checkers are all external programs. I don't know what the
default is on OSX.

Is it possible you accidentally told the spell checker to accept this word?

Richard



Testing of the 2.2.x Branch (esp Slowness)

2017-01-06 Thread Richard Heck
We (specifically, Jean-Marc Lasgouttes) have recently made some changes
to the text rendering algorithms in LyX. We would appreciate it if those
who are able could compile and use the 2.2.x branch of the git
repository, so that these changes can receive sufficient testing before
we schedule the release of LyX 2.2.3.

For those on Linux, this should not be terribly difficult. You will need
to install some headers libraries, e.g., zlib-devel and especially
qt-devel (naming may vary on various distros), as well as the usual
compilation tools (automake, make, gcc). You will also need to install
git to be able to check out the repo. But the compilation procedure is
otherwise fairly straightforward.

Do this, from whatever directory you choose (in which you have write
privileges):

> git clone git://git.lyx.org/lyx/
> cd lyx
> git checkout 2.2.x

You have now checked out the 2.2.x branch, which is what will become
2.2.3. Have a look, if you wish, at the INSTALL file for some
information about what else you may need to do. Compiling is then the
usual three-step:

> ./autogen.sh
> ./configure --enable-build-type=rel

This flag gives you a "release version" rather than a "development
version", which is what 2.2.3 would actually be.

> ./configure --help

if you want more information on other options. It is, for example,
possible to install LyX to a location other than the default, which is
/usr/local/, and which will normally require root privileges.

You may find that configuation fails. This will usually be due to your
not having all the dependencies installed. The configuation script is
usually pretty good at telling you what you need. If you have problems,
then please respond to this email, and we'll help.

> make
> sudo make install

You can add an option "-j N" to the first command make to speed things
up. This tells make to compile N files simultaneously. Roughly speaking,
you can set N to the number of cores you have (or even a few more).

Richard Heck
Stable Branch Maintainer




Re: Trojan in LyX ?!

2016-12-08 Thread Richard Heck
On 12/08/2016 08:22 AM, Max Peterson wrote:
> I have tried to check it. Result:
>
> Inline-Bild 1

You need to import the LyX key.

Richard



Re: TODO notes (double entries) in LyX 2.2.2 on Windows 10

2016-12-07 Thread Richard Heck
On 12/07/2016 08:14 PM, Cris Fuhrman wrote:
> My first email had an attachment of a lyx file (perhaps it didn't go
> through?)
>
> Anyway, it's definitely a bug in TODO notes... I even think I found
> the bug in the source
> at https://github.com/henrikmidtiby/todonotes/issues/22 (see my comment).

So it looks as if this is a bug in the LaTeX package, then, not in LyX?

Richard


>
> On Wed, Dec 7, 2016 at 6:43 PM, Richard Heck <rgh...@lyx.org
> <mailto:rgh...@lyx.org>> wrote:
>
> On 12/01/2016 11:14 AM, Cris Fuhrman wrote:
>> I've recently noticed an odd behavior of TODO Notes in LyX 2.2.2.
>> I enabled the fancyline option, and I saw I was getting two
>> lines. Upon further debugging (using author= and size=\tiny), I
>> can prove that it's actually generating two TODO notes at the
>> same place. Here's a screen grab:
>>
>> Inline image 1
>> I'm attaching the minimal example (used in LyX 2.2.2 under
>> Windows 10). I updated my MikTeX yesterday to see if it would go
>> away, but no luck. It's reproducible on BOTH my Windows 10
>> machines with LyX.
>>
>> I searched for todonotes modules (as I used it before prior to
>> LyX 2.2 before it was part of the distribution), but I couldn't
>> find anything in my LyX path directories that looked like a
>> duplicate. I'm not sure how this is happening.
>>
>> When I paste the LaTeX source from LyX (pasted below) into a
>> TeXstudio document, it works perfectly, so I don't think it's my
>> TeX installation.
>
> That's pretty strange. Can you post an example file?
>
> Richard
>
>



Re: TODO notes (double entries) in LyX 2.2.2 on Windows 10

2016-12-07 Thread Richard Heck
On 12/01/2016 11:14 AM, Cris Fuhrman wrote:
> I've recently noticed an odd behavior of TODO Notes in LyX 2.2.2. I
> enabled the fancyline option, and I saw I was getting two lines. Upon
> further debugging (using author= and size=\tiny), I can prove that
> it's actually generating two TODO notes at the same place. Here's a
> screen grab:
>
> Inline image 1
> I'm attaching the minimal example (used in LyX 2.2.2 under Windows
> 10). I updated my MikTeX yesterday to see if it would go away, but no
> luck. It's reproducible on BOTH my Windows 10 machines with LyX.
>
> I searched for todonotes modules (as I used it before prior to LyX 2.2
> before it was part of the distribution), but I couldn't find anything
> in my LyX path directories that looked like a duplicate. I'm not sure
> how this is happening.
>
> When I paste the LaTeX source from LyX (pasted below) into a TeXstudio
> document, it works perfectly, so I don't think it's my TeX installation.

That's pretty strange. Can you post an example file?

Richard



Re: Trojan in LyX ?!

2016-12-06 Thread Richard Heck
On 12/06/2016 02:41 PM, Cris Fuhrman wrote:
> It's good to be paranoid. I suspected a virus, too, weeks ago when
> 2.2.2 was released (my Microsoft anti-virus even deleted the download
> before I could run it!). However, VirusTotal shows that a minority of
> the virus detectors see a Trojan in the installer exes distributed for
> LyX, but most do not:
>
> https://www.virustotal.com/en/file/f6a843b13bcbbcf7e7ae6cba3842f55b73d0327834e55fd47ec2a7314975ebd0/analysis/
>
> Also, when I check the signatures with "gpg" (using a git bash in
> Windows 10), I see "Good signature" (my emphasis below):

Just to emphasize a point made earlier: This verifies that the file is
the same as the one that *I* uploaded. Uwe does not sign the binaries he
sends me, so I have no way to verify that they are the same as the ones
he produced.

If you know how to set up signing, etc, on Windows, perhaps you could
help Uwe get that set up on his machine? If so, perhaps you could email
him at uwesto...@lyx.org and cc me and we can try to sort this out?

Richard



Re: "Local Layout" in external file?

2016-11-23 Thread Richard Heck
On 11/23/2016 04:49 AM, Klaus-Dieter Bauer wrote:
> 2014-11-13 11:20 GMT+01:00 Klaus-Dieter Bauer
> <bauer.klaus.die...@gmail.com <mailto:bauer.klaus.die...@gmail.com>>:
>
> 2014-11-07 19:50 GMT+01:00 Richard Heck <rgh...@lyx.org
> <mailto:rgh...@lyx.org>>:
>
> On 11/07/2014 10:25 AM, Klaus-Dieter Bauer wrote:
>
> Hello!
>
> Is there a method to share document settings (document
> class, font size, ...) across all subdocuments of a project?
>
> My intention is to be able to compile each file separately
> (for faster debugging), with changes to document settings
> being automatically shared across all files and explicitly
> WITHOUT manually changing settings like \includeonly or
> commenting-out include statements.
>
>
> Note that Document> Settings> Child Documents provides a
> different way to do this. But I understand the desire to
> compile the documents separately. And that can sort of be done.
>
> If you can get the settings right at the start, then you can
> put them into a sort of template file and use that to start
> all your documents. But if you need to change something,
> you'll have to change it manually in each of the
> sub-documents. The exception is anything you put in the LaTeX
> preamable. That can be synchronized by putting it all into
> some common file and then incuding that.
>
> Richard
>
> Since I found manually changing the documents tiresome, I wrote a
> script that extracts, overwrites and copies the header section
> between lyx files and uploaded it to
>
> https://gist.github.com/kbauer/2282492968f061b94f82
> <https://gist.github.com/kbauer/2282492968f061b94f82>
>
>
> Picking up on my old question again, with a more limited scope: Is
> there some feature that allows putting the "local layout" in an
> external file, that is local to the current project (e.g. in the same
> directory as the lyx file)?

No. This facility does exist for layout files, but it causes all kinds
of problems, and I've meant for some years to remove it.

> I am recently heavily using the "local layout" feature in my
> documents. This does however come with some disadvantages, notably a
> very limited internal editor and the need to manually (or with an
> external script) synchronize the setting across multiple files of a
> project. Installing them as system-wide modules isn't a good solution
> either, when I want to ensure that files that were created with an old
> version of my local-layout will still compile in the future, let alone
> on other people's LyX-installation – or my own in three years.

We've discussed the possibility before of allowing for the possibility
of launching an external editor, etc, for Local Layout. But no one has
ever done it.

I'm not totally sure why installing them as modules is a bad idea.
Perhaps "system-wide" is meant to indicate that you aren't putting them
in your local user directory?

Richard



Re: Fragility

2016-11-18 Thread Richard Heck
On 11/18/2016 06:36 AM, F M Salter wrote:
> Examples:
>
> I was annotating a file using the PDF comments module.  The
> pdfmarkup annotations were working correctly, visible in the pdf
> output.  I edited some text.  In subsequent version of this document
> no markups are visible in the  pdf output.  I have more than forty
> similar files all producing the expected annotated results.
>

Without a concrete example, it is difficult to know what would cause
this. Similar problems, though, have sometimes been caused by the
cut-and-paste of illegal characters, which LaTeX then chokes on. But, as
I say, it's hard to know. The way to proceed (and to help us find and
fix the bug, if such there is) is to start eliminating various parts of
the file and see if the problem remains. I.e., if you delete the entire
second half, do you still see this problem? What about the first half?
Continuing to do this is known as "bisecting". It helps localize the
problem, at which point it can be addressed.

> Tables:  With formal tables the order of editing can produce
> different outcomes.  I have worked round  this problem by starting a
> completely new table as the subsequent editing of erroneous tables has
> produced  variable,  unexpected and inappropriate results.
>

Here again, related problems have sometimes been reported, but this is
too abstract to do anything with. The table code is complex, possibly
too complex. It's not clear to me that it is really a good idea to try
to do really complicated table stuff in LyX itself.

> hyperref:unticking hyperref, after its having been set,
> produces a number of error messages and output with "hyperrefImplicit
> mode ON; LaTeX internals redefined" on the first page numbered 1. The
> rest of the document starts on the page numbered 2!
>

In general, I do not see this. If it's happening in a particular
document, then I'd want to know more about the details of that document.
Again, bisecting may help.

> biblatex with biber: Possibly it is to be expected to be more
> delicate.  However, with a new pdf requiring more than 20 seconds to
> be produced, human error is likely and can lead to an inability to
> produce any further pdf output.  Solution is close down LyX and restart.
>

LyX doesn't support this natively. It's definitely an "advanced"
technique, meaning that one should indeed expect it to be more delicate.

Richard



Re: tex2lyx error

2016-11-18 Thread Richard Heck
On 11/17/2016 05:36 PM, Jay A. Leavitt, PhD wrote:
> Running Win 10, LyX 2.2.2
> template.tex is a template for Springer publications. Latex files with
> Springer macros cannot import into LyX.
> LyX: Cannot convert file. An error occurred while running:
> tex2lyx -fixedenc utf8 -f "template.tex" "template.lyx"

I would guess that the problem is that the file uses a document class
for which there is no layout file. What document class does it use?

Richard



Re: Numbering of Theorems, etc.

2016-11-18 Thread Richard Heck
On 11/17/2016 03:42 PM, Andrew Parsloe wrote:
>
>
> On 18/11/2016 5:43 a.m., Richard Heck wrote:
>> On 11/17/2016 04:42 AM, Andrew Parsloe wrote:
>>>
>>> LyX doesn't supply all the modules necessary to use AMS environments
>>> numbered by type within chapters. I ran into this problem some weeks
>>> ago but found I could create or adjust the necessary modules using the
>>> supplied ones as models. I've attached the new/adjusted ones to this
>>> email. Place them in the layouts folder of your personal LyX
>>> directory. Then you will need to reconfigure LyX so it knows of them.
>>>
>>> There are dependencies among the modules which is why some can't be
>>> added or deleted without others.
>>
>> Thanks for these. I've committed them, but I guess I should first have
>> asked for a GPL declaration, so I can add you to the credits. Can you
>> just send a short email to lyx-devel saying something like: I hereby
>> agree to license my contributions to LyX under the General Public
>> License, version 2 or any later version?
>>
>> Richard
>>
>
> OK, I'll do that, although my contribution was largely mechanical. I
> gather from comments in the modules that the "real work" was done by
> Paul Rubin building on earlier work by you.

It's probably not essential for licensing purposes, but you deserve the
credit.

Richard



Re: Numbering of Theorems, etc.

2016-11-17 Thread Richard Heck
On 11/17/2016 04:42 AM, Andrew Parsloe wrote:
>
> LyX doesn't supply all the modules necessary to use AMS environments
> numbered by type within chapters. I ran into this problem some weeks
> ago but found I could create or adjust the necessary modules using the
> supplied ones as models. I've attached the new/adjusted ones to this
> email. Place them in the layouts folder of your personal LyX
> directory. Then you will need to reconfigure LyX so it knows of them.
>
> There are dependencies among the modules which is why some can't be
> added or deleted without others.

Thanks for these. I've committed them, but I guess I should first have
asked for a GPL declaration, so I can add you to the credits. Can you
just send a short email to lyx-devel saying something like: I hereby
agree to license my contributions to LyX under the General Public
License, version 2 or any later version?

Richard



Re: Numbering of Theorems, etc.

2016-11-16 Thread Richard Heck
On 11/16/2016 04:03 AM, Bernt Lie wrote:
>
> *From:*Richard Heck [mailto:rgh...@lyx.org]
> *Sent:* tirsdag 15. november 2016 19.04
> *To:* Bernt Lie <bernt@hit.no>; LyX Users <lyx-users@lists.lyx.org>
> *Subject:* Re: Numbering of Theorems, etc.
>
>  
>
> On 11/15/2016 09:43 AM, Bernt Lie wrote:
>
> I use LyX 2.2.1 (currently) on Windows 10.
>
>  
>
> I have a rather long document (some 600 pages, with 9 chapters +
> several appendices), and want to number Exercises, Problems,
> Examples, Theorems, etc. **independently** and numbered **by the
> chapter** (or appendix) they appear in. Thus, exercises in chapter
> 6 should be numbered Exercise 6.1, Exercise 6.2, etc., while
> examples in chapter 6 should be numbered Example 6.1, Example 6.2,
> etc.
>
>  
>
> Currently, this doesn’t work. My set-up is:
>
> · Document class: Book (Standard Class)
>
> · Modules: Theorems (AMS, Numbered by Type)
>
>  
>
> What else do I need to set?
>
>
> I assume the problem is that you are not getting the "numbered by
> chapter" bit? If so, then maybe the easiest thing to do is use the
> internal LaTeX command \@addtoreset in the preamble, thus:
> \@addtoreset{theorem}{chapter}
> Now the theorem counter gets reset whenever the chapter counter is reset.
>
> You'll need to do the same thing for any other counters you are using,
> and see the theorems-ams-bytype.inc file for the names of the various
> counters.
>
> See also: http://www.tex.ac.uk/FAQ-addtoreset.html.
>
> Richard
>
> --
>
> Richard,
>
> Thanks for quick reply. I’ve tested it (inserting
> “\@addtoreset{theorem}{chapter}” in the preamble), but now get the
> following error messages:
>
>  
>
> OK. Let me try to be a little bit more precise. Currently, the
> counters count independently. In other words, Definition 1, Definition
> 2, Theorem 1, Definition 3, Theorem 2, Example 1, etc.
>
>  
>
> However, they (i) do not contain a chapter counter, and (ii) they do
> (obviously) not reset the chapter counter in each chapter.
>

See the attached. Sorry, I got the names of the counters wrong. (I mixed
up the LyX counters and the LaTeX ones.) The LaTeX names are the same as
the names of the environments as they are declared in the preamble, e.g.:
\newtheorem{lem}{\protect\lemmaname}
So the counter is "lem" for Lemmas.

Richard



ch.lyx
Description: application/lyx


Re: Numbering of Theorems, etc.

2016-11-15 Thread Richard Heck
On 11/15/2016 09:43 AM, Bernt Lie wrote:
>
> I use LyX 2.2.1 (currently) on Windows 10.
>
>  
>
> I have a rather long document (some 600 pages, with 9 chapters +
> several appendices), and want to number Exercises, Problems, Examples,
> Theorems, etc. **independently** and numbered **by the chapter** (or
> appendix) they appear in. Thus, exercises in chapter 6 should be
> numbered Exercise 6.1, Exercise 6.2, etc., while examples in chapter 6
> should be numbered Example 6.1, Example 6.2, etc.
>
>  
>
> Currently, this doesn’t work. My set-up is:
>
> · Document class: Book (Standard Class)
>
> · Modules: Theorems (AMS, Numbered by Type)
>
>  
>
> What else do I need to set?
>

I assume the problem is that you are not getting the "numbered by
chapter" bit? If so, then maybe the easiest thing to do is use the
internal LaTeX command \@addtoreset in the preamble, thus:
\@addtoreset{theorem}{chapter}
Now the theorem counter gets reset whenever the chapter counter is reset.

You'll need to do the same thing for any other counters you are using,
and see the theorems-ams-bytype.inc file for the names of the various
counters.

See also: http://www.tex.ac.uk/FAQ-addtoreset.html.

Richard



Re: Package {extract} into lyx

2016-10-26 Thread Richard Heck

I don't know how to solve this problem---I'm top-posting since the
details below don't matter much---but I can say how to go about solving it.

Since you are comfortable with LaTeX, figure this out at the LaTeX level
first, and ignore LyX. So, e.g,. create a simple file, based on
article.cls, and include a variety of types of equations, e.g., align*
and other things that seem to be causing problems. You may need to try
putting the line that loads extract in different places. Does this work?
If not, the problem lies in extract's treatment of those environments.
If it does work, try shifting the document class to classic-thesis. Does
that work? If not, then there's some incompatibility between
classic-thesis and extract. Those are both LaTeX issues. I'd try writing
the extract maintainer, or asking on comp.text.tex or somewhere like that.

If all is well on the LaTeX side, try importing your simple LaTeX file
into LyX. Alternatively, just try creating the same kind of file in LyX.
If it no longer works, then export it back to LaTeX and compare the two
files. They will be different. It may be that the line that's loading
extract is coming at a different place.

Richard


On 10/26/2016 11:42 AM, Riccardo wrote:
> Indeed it is very useful in my opinion!
> By the way, sorry for the poor explanation. I'll try to better explain
> the problem:
>
> *In latex* with a Minimal.tex (attached) you run
> latex Minimal.tex
> and the line
> \usepackage[active,generate=filename,extract-env={align,equation}]{extract}
> generate a filename.tex(attached), attaching to it every align and
> equation environment found in Minimal.tex.
>
> In my case, however, I'm using *LyX with classicthesis template*.
> Being it based on a latex template, I thought it'd be easy to modify
> the preamble classicthesis-config.tex (in fact it worked in the past
> with some other packages). I tried to add the following lines to the 
> package list loaded
>
> \PassOptionsToPackage[active,
> \PassOptionsToPackage[active,generate=file,
> extract-env={equation,align}]{extract}
> \usepackage{extract}
>
> and I got many errors (not relevant showing them, please read the
> following).
>
> Then, I tried adding to the Latex preamble
>
> \usepackage[active,generate=file,extract-env={equation,align}]{extract}
>
>
> via the Document->Setting->LatexPreamble dialog, with a little more
> luck. At first, I got many identical errors concerning the package
> extract handling of unnumbered equations environment (please refer to
> the package documentation):
>
> ! LaTeX Error: \begin{XTRalign*} on input line 1 ended by \end{XTRalign}.
>
>
> See the LaTeX manual or LaTeX Companion for explanation.
>
> Type H  for immediate help.
>
> ...
>
> l.4 \end{XTRalign*}
>
> Your command was ignored.
>
> Type I   to replace it with another command,
>
> or  to continue without it.
>
>
> Removing every {align*} and {eqnarray*} environment, leaving numbered
> equations only, a proper "file.tex" is created in the temporary log
> folder, with every numbered formula attached.So now my questions are:
>
> 1. Has anyone encountered the same problem? Do you now any fix to the
> align* issue?
> 2. Do you know any alternative, possibly with a Lyx file output
> instead of a latex one? Formatting and tipography issue are not
> relevant for me, since this would be just an auxiliary file for me to
> check while writing.
>
> Thanks in advance
> Riccardo
>
> 2016-10-26 15:32 GMT+02:00 Scott Kostyshak  >:
>
> On Wed, Oct 26, 2016 at 02:31:03PM +0200, Riccardo wrote:
> > Hello,
>
> Hi Riccardo,
>
> > do anybody have ever used the package extract in LyX (possibly in
> > combination with classicthesis)?
>
> I have not used it, but it looks interesting and useful!
>
> > I'm writing my thesis and I'd like to
> > check the consistency of the notation throughout it, focusing on
> math only.
> > Are there any alternatives?
> > If I use the package as suggested in the CTAN repository
> documentation, Lyx
> > fails with a number of errors.
>
> For issues like this, please always say explicitly which errors
> you get
> and please also attach a minimal example. See here for more
> information:
>
> https://wiki.lyx.org/FAQ/MinimalExample
> 
>
> Scott
> >
> > Riccardo
>
>



Re: Automatically add \leavevmode after amsthm example

2016-10-21 Thread Richard Heck
On 10/21/2016 03:38 PM, Florian Dollinger wrote:
> Hi folks!
>
> Can anyone tell me how I can modify the theorems-ams file to the
> effect that there is automatically added a \leavevmode?
> I often use lists inside the example environment like in the attached
> picture.

Is there some reason you need \leavevmode? I think a simpler thing to do
is just to put LyX's equivalent of a protected space.

But if you do want to do this, try the following in Local Layout:

Format 60

Style Example*

KeepEmpty 1

LaTeXParam "\leavevmode"

End

It's a bit of a hack, but it works. Note that the LaTeXParam could also
be "~", or anything else you wish. Doing it this way of course affects
all Example* environments, so if you don't want to do that, try:


Format 60 Style ExampleEmpty

CopyStyle Example*

KeepEmpty 1

LaTeXParam "\leavevmode"

End

Now you have a new one.

> Another question: is there any ntheorem module?

Not yet.

Richard



[ANNOUNCE] LyX 2.2.2 for OSX

2016-10-17 Thread Richard Heck
Attention OSX users: The original binary package for LyX 2.2.2 on recent
OSX systems had a problem, apparently due to the Qt version used, that
caused serious problems with sub-menus. A new package was uploaded
yesterday. If you are not experiencing this kind of issue, don't worry
about it. If you are, try downloading the new package.




Re: [ANNOUNCE] LyX 2.2.2 Released

2016-10-15 Thread Richard Heck
On 10/15/2016 08:36 PM, Uwe Stöhr wrote:
> Am 15.10.2016 um 18:11 schrieb Richard Heck:
>
>> Public release of LyX version 2.2.2
>
> Unfortunately lyx.org is currently down.
>
> LyX 2.2.2 can nevertheless be downloaded via our FTP server:
> http://ftp.lyx.org/pub/lyx/bin/2.2.2/

Please do not announce such things on this list. That binary is not signed.

And you should be signing yours.

Richard



Re: [ANNOUNCE] LyX 2.2.2 Released

2016-10-15 Thread Richard Heck
On 10/15/2016 02:41 PM, Christopher Menzel wrote:
>> Public release of LyX version 2.2.2
>> ===
>> We are proud to announce the release of LyX 2.2.2. This is the
>> secondmaintenance release in the 2.2.x series
>
> I've said it before but it bears regular repeating: thanks (again)
> Richard and the whole LyX development team for this wonderful,
> incredibly useful piece of software. It is an absolute joy to use, and
> a marvel of collaborative, open source software design and engineering.

You're welcome. And thanks for the thanks.

Richard



  1   2   3   4   5   6   7   8   9   10   >