Changeset 562ccf9 for doc/LaTeXmacros


Ignore:
Timestamp:
Aug 25, 2024, 11:53:34 AM (4 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
3f37f5b
Parents:
38f6e66
Message:

remove empty line number increment from listings

Location:
doc/LaTeXmacros
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • doc/LaTeXmacros/common.sty

    r38f6e66 r562ccf9  
    1111%% Created On       : Sat Apr  9 10:06:17 2016
    1212%% Last Modified By : Peter A. Buhr
    13 %% Last Modified On : Mon Jun 24 08:03:28 2024
    14 %% Update Count     : 659
     13%% Last Modified On : Sun Aug 25 11:52:19 2024
     14%% Update Count     : 661
    1515%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1616
     
    267267\usepackage{listings}                                                                   % format program code
    268268\usepackage{lstlang}
     269
     270\lst@AddToHook{OnEmptyLine}{\addtocounter{lstnumber}{-1}}% remove empty line number increment from listings
    269271
    270272\newcommand{\LstBasicStyle}[1]{{\lst@basicstyle{#1}}}
  • doc/LaTeXmacros/common.tex

    r38f6e66 r562ccf9  
    1111%% Created On       : Sat Apr  9 10:06:17 2016
    1212%% Last Modified By : Peter A. Buhr
    13 %% Last Modified On : Mon Jun 24 08:01:50 2024
    14 %% Update Count     : 667
     13%% Last Modified On : Sun Aug 25 11:52:20 2024
     14%% Update Count     : 673
    1515%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1616
     
    271271
    272272\makeatletter
     273\lst@AddToHook{OnEmptyLine}{\addtocounter{lstnumber}{-1}}% remove empty line number increment from listings
     274
    273275\newcommand{\LstBasicStyle}[1]{{\lst@basicstyle{#1}}}
    274276\newcommand{\LstKeywordStyle}[1]{{\lst@basicstyle{\lst@keywordstyle{#1}}}}
Note: See TracChangeset for help on using the changeset viewer.