LyXTOC: Overset Text

Information and discussion about LyX, a WYSIWYM editor, available for Linux, Windows and Mac OS X systems.
Post Reply
aahamm
Posts: 5
Joined: Fri Oct 03, 2014 5:03 pm

TOC: Overset Text

Post by aahamm »

Hi Folks!

Make my first experience with latex via Lyx right now finishing my master thesis.
I found a problem I´m not able to solve or to find anything. Maybe because I don´t now the right keywords in english to find a solution... so please help me if possible.

I have overset text in my table of contents as you can see here... and also the rest of it looks like.... erm... shit somehow. :D
I also would like to change the used font and have the same font for the page number for sections as for the subsection.
Pi0XFn0.jpg
Pi0XFn0.jpg (56.92 KiB) Viewed 6362 times
How can i repair this?
I´m using standard article as this suits the guidelines of my institution (which hasn´t any for LaTeX) best.
Last edited by Johannes_B on Fri Oct 03, 2014 5:27 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

TOC: Overset Text

Post by Johannes_B »

What you have shown doesn't show any resemblance to the standard article. I guess there is a lot of stuff going on in the background. But i can't see it.

You are addressing multiple issues, all of which are not standard behaviour. It would be better to figure out things one by one. The best way to hack down to the reason for a special behaviour is making a minimal working example (or in german Minimalbeispiel). Using LyX, there is a similar approach, a minimal LyX example.

I heard the guys over at TeXwelt are nice, you might want to take a look around.


On a personal matter, are you sure you have the current and up-to-date guidelines or is the typewriter look a special feature?
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
aahamm
Posts: 5
Joined: Fri Oct 03, 2014 5:03 pm

Re: TOC: Overset Text

Post by aahamm »

Hi Johannes!

Okay, I figured out, that he doesn`t hyphenate with the long words in my headlines. That is the main problem.

Here is an minimal working example with this mistake(s) in it:
https://drive.google.com/file/d/0B7oTVt ... sp=sharing

Still up the question with the typewriter font and the wrong page number font for the section.

edit: I forgot to put that right: I want to get rid of the typewriter font!
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Re: TOC: Overset Text

Post by Johannes_B »

To be honest, i don't have LyX installed and can't test your file.

You can export it to LaTeX tough and post the code between the

Code: Select all

 LaTeX code [code] brakets (or simply click the code-button.

We have a few LyX helpers coming here occasionally, but we might find an answer sooner.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
aahamm
Posts: 5
Joined: Fri Oct 03, 2014 5:03 pm

TOC: Overset Text

Post by aahamm »

That would be just great! Really appreciate your help! :)

Code: Select all

%% LyX 2.1.1 created this file.  For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[12pt,naustrian]{article}
\usepackage{mathptmx}
\renewcommand{\familydefault}{\rmdefault}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage[a4paper]{geometry}
\geometry{verbose,tmargin=3.5cm,bmargin=3.5cm,lmargin=3.5cm,rmargin=3.5cm,headheight=1cm,headsep=1cm,footskip=1.5cm}
\setcounter{secnumdepth}{5}
\setcounter{tocdepth}{5}
\setlength{\parskip}{\smallskipamount}
\setlength{\parindent}{0pt}
\usepackage{setspace}
\onehalfspacing

\makeatletter
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands.
\newenvironment{lyxcode}
{\par\begin{list}{}{
\setlength{\rightmargin}{\leftmargin}
\setlength{\listparindent}{0pt}% needed for AMS classes
\raggedright
\setlength{\itemsep}{0pt}
\setlength{\parsep}{0pt}
\normalfont\ttfamily}%
 \item[]}
{\end{list}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
\usepackage{subfigure}
\usepackage[bottom]{footmisc}
\renewcommand{\footnotesep}{1em}
\interfootnotelinepenalty=10000
\date{}

\makeatother

\usepackage{babel}
\begin{document}
\begin{lyxcode}
\tableofcontents{}

\newpage{}
\end{lyxcode}

\section{Einleitung}

\section{Was ist Spiel? - Eine Begriffsannäherung}

\section{Das Computerspiel - Begriffsannäherung und Geschichte}

\subsection{Was ist ein Computerspiel}

\subsection{Die Geschichte der Computerspiele}

\subsubsection{Frühe (Proto-)Computerspiele}

\subsubsection{Magnavox Odyssey}

\subsubsection{Ataris Pong}

\subsubsection{Entwicklung und Krise 1983}

\subsubsection{Vom Commodore 64 zu den modernen Spielkonsolen}

\subsubsection{Der PC als Spieleplattform}

\subsubsection{Smartphones und Tablets als neuer Markt}

\subsection{Relevanz und Verbreitung}
\end{document}
Attachments
sample.zip
(1019 Bytes) Downloaded 215 times
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

TOC: Overset Text

Post by Johannes_B »

Your table of contents somehow got inside a lyxcode environment.


In the Lyx-file, you can see it here:

Code: Select all

\begin_layout LyX-Code#<- this shouldn't be here
\begin_inset CommandInset toc
LatexCommand tableofcontents

\end_inset


\end_layout#i think this is the counterpart
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
aahamm
Posts: 5
Joined: Fri Oct 03, 2014 5:03 pm

Re: TOC: Overset Text

Post by aahamm »

Okay.... dunno how this got there, as i can´t edit the LaTeX source in Lyx.... must have smurfed something up somehow...

I now just copy/pasted everything but the TOC to a new and fresh file, did all my settings and now it works.

Thanks for helping me! Could have tried that earlier... but sometimes you just need a hand from outside to give you a nudge you into the right direction.
Last edited by Johannes_B on Fri Oct 03, 2014 7:28 pm, edited 1 time in total.
Reason: replaced a word that might be offensive to some people
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Re: TOC: Overset Text

Post by Johannes_B »

I think it would have sufficed if you deleted the toc and put it back there using the proper clicks.

Glad to see that things are fine now.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
aahamm
Posts: 5
Joined: Fri Oct 03, 2014 5:03 pm

Re: TOC: Overset Text

Post by aahamm »

Tried that first, but it didnt work...
Post Reply