Tag Info

New answers tagged

0

You can't have linebreaks within display math. Use align*, or gather* if you don't want alignment points. To have an alignment on the = sign, mark it with an ampersand: \begin{widetext} \begin{align*} a+b& =c;\\ d+e &= f;\\ e+m &= n;\\ \end{align*} \end{widetext} Note that you may have several alignment points. If you want to ...


1

To use non-TeX fonts in LyX, go to Document > Settings > Fonts and check "Use non-TeX fonts".


0

I do not know this, as I'm not really familiar with the internals of LyX, but I suspect that the answer is no. A workaround is however possible. First, if have selected Use non-TeX fonts in Document --> Settings --> Fonts, uncheck this. In the LaTeX preamble, add the two packages in the required order. If you had chosen a specific font in the font ...


1

As noted above, you need to use paste special, to keep the line breaks. You may also wish to use a mono-spaced environment, like 'verbatim' or 'LyX-code' so that your "tree" characters line up. If so, begin a new paragraph, select one of the two mono-spaced styles and then paste special. For me, ctl + shift + v is a shortcut for paste special.


2

One option is to use the dirtree package. In Document>Settings>LaTeX preamble, insert this code: \usepackage{dirtree} In the main text, open an ERT box (Ctrl+L) and write something like: \dirtree{% .1 Tree. .2 AndroidManifest.xml. .2 res. .3 drawable-hdpi. .4 color\_orange.png. } The result must be the same that this MWE in LaTeX: ...


1

Try adding the "Customisable lists (enumitem)" module to your master document and each child document. Then change each of your lists from enumerate to enumerate-resume. I haven't tried it, but I think this would do what you want with the numbers. However, if you want one big list then the spacing won't be right; there will be extra space between the parts ...


2

No, you have to avoid greek letters, german umlauts, and whatever strange glyphs in your path and filenames. Even if the OS -- seems Windows in your case -- can handle the non ASCII letters, the texlive and MikTeX installations below Lyx can't. I avoid even spaces in the filenames and signs like +,#,~, accents, dots (except one), ... If you'd like to have ...


2

There is no one duplicate of your question, though most parts of the answer can be found in other questions, such as How do I add syntax coloring to my C++ source code in beamer Lyx is ignoring typewriter font setting for program listings When you do Insert --> Program Listing, or Insert --> File --> Child document --> Program listing, LyX uses the ...


3

Select some text. Then, under the menu Edit > Text Style > Customize... (or right-click Text Style > Customize...) Under Shape, select Italic: This translates to \textit from LaTeX's point of view. Alternatively you can emphasize an item (translated to LaTeX's \emph) by using Ctrl + E.


1

There is a convoluted menu system for this, but the shortcut is Ctrl + E. The 'e' stands for emphasis.


3

For the specific case of fontenc, go to Document --> Settings --> Fonts, set LaTeX font encoding to Custom, and type whichever font encoding you wish in the input field. In general, as in this answer to a similar question, to pass an option to a package you can put it in the document class options. This will pass those options to all packages, so it's ...


2

You haven't provided any information about how the citation commands are formed and if you use a citation management package. The following suggestion thus definitely constitutes a stab in the dark. If the "only" problem that's left to solve is the reversed ordering of the square brackets, you could try loading the cite package and issuing the commands ...


1

Ok, if I understand you correctly, you've noticed that when you cut/copy and paste something like a fraction then one of the entries gets lost. I can verify this, and it's a bug in LyX; maybe it would be sensible to add it to their bug tracker. However, it only happens in a very specific situation, which you can usually work around. I suspect that this ...


1

It depends on what you want. If there is a lot of text between the two points, and the enumerate is somehow "within the text" (if you see what I mean), then you should enumerate-resume as scottkosty says. But if you want the text between the bullet points to be "within the enumerate", then this is supported in LyX as follows, without the need for extra ...


3

The easiest way to disable editing in LyX is to View > Toolbars > Command buffer (or simply alt+x, and in the command buffer executing buffer-toggle-read-only To make the document editable again you need to redo the above. If you do this often, then it would be easier to define a new menu entry (see related bug report). Proceed as follows (on ...


2

I had the same problem and this is what resolved it for me: reinstall latest version MacTeX at: https://tug.org/mactex/ install latest version of LyX: 2.1.1. (see: http://www.lyx.org/Download) Tools --> Reconfigure. Restart, check: Document --> Settings --> Document Classes: these should now be available. I see from your question that you had already ...


3

You will need the customizable lists (enumitem) module. Once you add that (in Document > Settings> Modules), to resume an enumeration, go to the dropdown list in the upper-right (that probably says either "enumerate" or "standard") and just "Enumerate-Resume" Here is an example .lyx file (requires LyX 2.1 to open): #LyX 2.2 created this file. For more info ...


1

I have no idea if this is the correct way to do it (I don't know how to write in Chinese), but it appears to work for me. Note that I'm on Ubuntu with TeX Live 2014 and am using LyX 2.1.1. Before trying this, first make sure you can export LyX's Chinese manuals as a test that you have all of the prerequisites. Open doc/zh_CN/Intro.lyx and ...


0

I do not know how the custom .bind files work on Mac, so I can offer no insights about that. However, seeing that the shortcut you want to define begins with Ctrl + f, your problem might have arisen due to a binding conflict. On Ubuntu, for example, Ctrl + f is by default bound to dialog-show findreplace. I've heard rumors that on Mac it is bound ...


1

To define a hyphen for use as part of a hyphenated name in a macro, I used the command \def\mymathhyphen{{\hbox{-}}}. This gives the usual en-dash.


3

Like this: \documentclass[12pt]{article} \usepackage{listings} \usepackage{xcolor} \newcommand{\hilight}{\makebox[0pt][l]{% \color{yellow}\rule[-4pt]{0.65\linewidth}{14pt}}% } \begin{document} \begin{lstlisting}[language=C,escapechar=\%] public static void function(){ int i=0; %\hilight%char j = malloc(sizeof(char)); /.......some ...


2

In general, all TikZ commands has to be ended by a semicolon, so your code snippet should be \begin{tikzpicture} \draw (0,0)--(1,2)--(2,0); \draw[help lines] (0,0) grid (2,3); \end{tikzpicture} If you ran a LaTeX document where such a terminating semicolon was missing, you'd get an error saying ! Package tikz Error: Giving up on this path. Did you forget ...


1

Here is a solution that will add a running header to all unnumbered chapters, so handle with care. It uses package etoolbox to prepend the markboth command you would do manually. Be careful, this code is bound to fail. Best to set the headers manually. Just to point that out, the right way to uppercase something is to use \MakeUppercase{<content>}. ...


5

LyX produce a LaTeX file and then call to pdflatex (or other compiler) to produce the PDF with this LaTeX file, so the results is the same. The point is decide if you are more comfortable editing directly the LaTeX source or the Lyx document. No doubt, LyX is much more attractive than LaTeX for novices because is a WYSIWYM editor (see Werner ...


0

Refer pdf doc "Page Layout in Latex" written by Piet van Oostrum. He says if you want get your chapter headings in Uppercases you have to use the following command \renewcommand{\chaptermark}[1]{% \markboth{\MakeUppercase{% \chaptername\ \thechapter.% \ #1}}{}} in the preamable after the line \pagestyle{fancy} Default: The header text is turned into all ...


1

One partial method is using Close inset as sugggested in the comments of your question. Here's an ad-hoc add-on: Edit the preferences in your boss' LyX installation to make the closed ERT insets invisible. In particular, go to Tools > Preferences > Look & Feel > Colors and change the color of LaTeX text to be the same as background, and do the ...


2

When you say formulas, I assume you mean formulas in a display: Insert > Math > Display Formula (there is a keyboard shortcut, but I don't remember what the default is). These are LaTeX \[ \] environments, and become \equation environments upon labeling or numbering. Once you have inserted your display, you right-click the display and may from there ...


6

I think all the important points have been covered, but there is one more aspect I would consider when looking at LaTeX (or even a programming language, photo editor, etc.). "How important is the interface, what do I do if it dies?" In the context of LyX and LaTeX, LaTeX really just needs its compiler and some text editor, the latter we can be certain will ...


9

Here is, I think, a fairly objective distinction between using LyX and editing LaTeX directly: LyX is very good at exporting to LaTeX. If you create a document in LyX with sections and theorems and equations then the PDF you create will be just as if you wrote it in LaTeX, because that's exactly what LyX did for you. LyX is extremely bad at importing from ...


27

I always recommend that you learn the basics of LaTeX before you learn LyX. LyX will not save you from learning LaTeX so you might as well learn it well from the start. After you really understand what LyX is doing (through LaTeX), you might find you like it better than using LaTeX directly. This is the case for me. This is also why I don't think LyX is a ...


11

LyX provides a more user-friendly front-end to latex. I find it more productive to work in general in LyX. However, by its nature it is not as flexible as pure latex. I do have to sometimes use LaTeXcode to achieve the desired results in LyX. That can be achieved either by setting things up in the document preamble or inserting latex code directly into ...


20

Q: What is the difference between LyX and LaTeX? A: From the LyX website: LyX is a document processor that encourages an approach to writing based on the structure of your documents (WYSIWYM) and not simply their appearance (WYSIWYG). LyX combines the power and flexibility of TeX/LaTeX with the ease of use of a graphical interface. This results in ...


0

I'll address your objectives sequentially: To get the desired citation style -- author(s) and year separated by comma, parentheses placed around the entire citation block -- you should use the citation command \citep to generate the citation callouts, and load the natbib package with the options comma and authoryear. To list all authors the first time ...


2

This thread seems to be closed fo quite a while, but as I found it right after searching for a solution some minutes ago, I just thought I could add the solution I found for solving the problem. For all those of you who use KOMA Script Classes: its just adding one line if you are going for changing the color of all headlines during your document; be it ...


0

The way LyX decides what to put in front of a formatted reference is by what label the thing has e.g. if you make a formatted reference to "thm:clever-result" then it will be formatted with "Theorem" at the front (even if the label's in a lemma!). So you need to make sure that the appropriate prefix is in each of your labels. With theorems, LyX puts "thm:" ...



Top 50 recent answers are included