mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-21 23:09:40 +00:00
merge lyx_sty.* into LaTeXFearures.cpp. was not used anywhere else
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18128 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
23d20f6935
commit
e941660705
@ -24,7 +24,6 @@
|
||||
#include "FloatList.h"
|
||||
#include "Language.h"
|
||||
#include "Lexer.h"
|
||||
#include "lyx_sty.h"
|
||||
#include "LyXRC.h"
|
||||
|
||||
#include "support/docstream.h"
|
||||
@ -47,6 +46,139 @@ using std::ostream;
|
||||
using std::ostringstream;
|
||||
using std::set;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Strings
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
|
||||
//\NeedsTeXFormat{LaTeX2e}
|
||||
//\ProvidesPackage{lyx}[1996/01/11 LLE v0.2 (LyX LaTeX Extensions)]
|
||||
//\message{LyX LaTeX Extensions (LLE v0.2) of 11-Jan-1996.}
|
||||
|
||||
static string const lyx_def =
|
||||
"\\providecommand{\\LyX}{L\\kern-.1667em\\lower.25em\\hbox{Y}\\kern-.125emX\\@}";
|
||||
|
||||
static string const lyxline_def =
|
||||
"\\newcommand{\\lyxline}[1][1pt]{%\n"
|
||||
" \\par\\noindent%\n"
|
||||
" \\rule[.5ex]{\\linewidth}{#1}\\par}";
|
||||
|
||||
static string const noun_def = "\\newcommand{\\noun}[1]{\\textsc{#1}}";
|
||||
|
||||
static string const lyxarrow_def =
|
||||
"\\newcommand{\\lyxarrow}{\\leavevmode\\,$\\triangleright$\\,\\allowbreak}";
|
||||
|
||||
// for quotes without babel. This does not give perfect results, but
|
||||
// anybody serious about non-english quotes should use babel (JMarc).
|
||||
|
||||
static string const quotedblbase_def =
|
||||
"\\ProvideTextCommandDefault{\\quotedblbase}{%\n"
|
||||
" \\raisebox{-1.4ex}[1ex][.5ex]{\\textquotedblright}%\n"
|
||||
" \\penalty10000\\hskip0em\\relax%\n"
|
||||
"}";
|
||||
|
||||
static string const quotesinglbase_def =
|
||||
"\\ProvideTextCommandDefault{\\quotesinglbase}{%\n"
|
||||
" \\raisebox{-1.4ex}[1ex][.5ex]{\\textquoteright}%\n"
|
||||
" \\penalty10000\\hskip0em\\relax%\n"
|
||||
"}";
|
||||
|
||||
static string const guillemotleft_def =
|
||||
"\\ProvideTextCommandDefault{\\guillemotleft}{%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'50\\kern-.15em\\char'50}%\n"
|
||||
"\\penalty10000\\hskip0pt\\relax%\n"
|
||||
"}";
|
||||
|
||||
static string const guillemotright_def =
|
||||
"\\ProvideTextCommandDefault{\\guillemotright}{%\n"
|
||||
" \\penalty10000\\hskip0pt%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'51\\kern-.15em\\char'51}%\n"
|
||||
"}";
|
||||
|
||||
static string const guilsinglleft_def =
|
||||
"\\ProvideTextCommandDefault{\\guilsinglleft}{%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'50}%\n"
|
||||
" \\penalty10000\\hskip0pt\\relax%\n"
|
||||
"}";
|
||||
|
||||
static string const guilsinglright_def =
|
||||
"\\ProvideTextCommandDefault{\\guilsinglright}{%\n"
|
||||
" \\penalty10000\\hskip0pt%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'51}%\n"
|
||||
"}";
|
||||
|
||||
static string const paragraphleftindent_def =
|
||||
"\\newenvironment{LyXParagraphLeftIndent}[1]%\n"
|
||||
"{\n"
|
||||
" \\begin{list}{}{%\n"
|
||||
" \\setlength{\\topsep}{0pt}%\n"
|
||||
" \\addtolength{\\leftmargin}{#1}\n"
|
||||
// ho hum, yet more things commented out with no hint as to why they
|
||||
// weren't just removed
|
||||
// "%% \\addtolength{\\leftmargin}{#1\\textwidth}\n"
|
||||
// "%% \\setlength{\\textwidth}{#2\\textwidth}\n"
|
||||
// "%% \\setlength\\listparindent\\parindent%\n"
|
||||
// "%% \\setlength\\itemindent\\parindent%\n"
|
||||
" \\setlength{\\parsep}{0pt plus 1pt}%\n"
|
||||
" }\n"
|
||||
" \\item[]\n"
|
||||
"}\n"
|
||||
"{\\end{list}}\n";
|
||||
|
||||
static string const floatingfootnote_def =
|
||||
"%% Special footnote code from the package 'stblftnt.sty'\n"
|
||||
"%% Author: Robin Fairbairns -- Last revised Dec 13 1996\n"
|
||||
"\\let\\SF@@footnote\\footnote\n"
|
||||
"\\def\\footnote{\\ifx\\protect\\@typeset@protect\n"
|
||||
" \\expandafter\\SF@@footnote\n"
|
||||
" \\else\n"
|
||||
" \\expandafter\\SF@gobble@opt\n"
|
||||
" \\fi\n"
|
||||
"}\n"
|
||||
"\\expandafter\\def\\csname SF@gobble@opt \\endcsname{\\@ifnextchar[%]\n"
|
||||
" \\SF@gobble@twobracket\n"
|
||||
" \\@gobble\n"
|
||||
"}\n"
|
||||
"\\edef\\SF@gobble@opt{\\noexpand\\protect\n"
|
||||
" \\expandafter\\noexpand\\csname SF@gobble@opt \\endcsname}\n"
|
||||
"\\def\\SF@gobble@twobracket[#1]#2{}\n";
|
||||
|
||||
static string const boldsymbol_def =
|
||||
"%% Bold symbol macro for standard LaTeX users\n"
|
||||
"\\providecommand{\\boldsymbol}[1]{\\mbox{\\boldmath $#1$}}\n";
|
||||
|
||||
static string const binom_def =
|
||||
"%% Binom macro for standard LaTeX users\n"
|
||||
"\\newcommand{\\binom}[2]{{#1 \\choose #2}}\n";
|
||||
|
||||
static string const mathcircumflex_def =
|
||||
"%% For printing a cirumflex inside a formula\n"
|
||||
"\\newcommand{\\mathcircumflex}[0]{\\mbox{\\^{}}}\n";
|
||||
|
||||
static string const tabularnewline_def =
|
||||
"%% Because html converters don't know tabularnewline\n"
|
||||
"\\providecommand{\\tabularnewline}{\\\\}\n";
|
||||
|
||||
static string const lyxgreyedout_def =
|
||||
"%% The greyedout annotation environment\n"
|
||||
"\\newenvironment{lyxgreyedout}{\\textcolor[gray]{0.8}\\bgroup}{\\egroup}\n";
|
||||
|
||||
// We want to omit the file extension for includegraphics, but this does not
|
||||
// work when the filename contains other dots.
|
||||
// Idea from http://www.tex.ac.uk/cgi-bin/texfaq2html?label=unkgrfextn
|
||||
static string const lyxdot_def =
|
||||
"%% A simple dot to overcome graphicx limitations\n"
|
||||
"\\newcommand{\\lyxdot}{.}\n";
|
||||
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// LaTeXFeatures
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
|
||||
LaTeXFeatures::PackagesList LaTeXFeatures::packages_;
|
||||
|
||||
|
||||
|
@ -185,8 +185,6 @@ lyx_SOURCES = \
|
||||
Server.h \
|
||||
ServerSocket.cpp \
|
||||
ServerSocket.h \
|
||||
lyx_sty.cpp \
|
||||
lyx_sty.h \
|
||||
LyXVC.cpp \
|
||||
LyXVC.h \
|
||||
MenuBackend.cpp \
|
||||
|
141
src/lyx_sty.cpp
141
src/lyx_sty.cpp
@ -1,141 +0,0 @@
|
||||
/**
|
||||
* \file lyx_sty.cpp
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Lars Gullik Bjønnes
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include "lyx_sty.h"
|
||||
|
||||
|
||||
namespace lyx {
|
||||
|
||||
using std::string;
|
||||
|
||||
|
||||
//\NeedsTeXFormat{LaTeX2e}
|
||||
//\ProvidesPackage{lyx}[1996/01/11 LLE v0.2 (LyX LaTeX Extensions)]
|
||||
//\message{LyX LaTeX Extensions (LLE v0.2) of 11-Jan-1996.}
|
||||
|
||||
string const lyx_def =
|
||||
"\\providecommand{\\LyX}{L\\kern-.1667em\\lower.25em\\hbox{Y}\\kern-.125emX\\@}";
|
||||
|
||||
string const lyxline_def =
|
||||
"\\newcommand{\\lyxline}[1][1pt]{%\n"
|
||||
" \\par\\noindent%\n"
|
||||
" \\rule[.5ex]{\\linewidth}{#1}\\par}";
|
||||
|
||||
string const noun_def = "\\newcommand{\\noun}[1]{\\textsc{#1}}";
|
||||
|
||||
string const lyxarrow_def =
|
||||
"\\newcommand{\\lyxarrow}{\\leavevmode\\,$\\triangleright$\\,\\allowbreak}";
|
||||
|
||||
// for quotes without babel. This does not give perfect results, but
|
||||
// anybody serious about non-english quotes should use babel (JMarc).
|
||||
|
||||
string const quotedblbase_def =
|
||||
"\\ProvideTextCommandDefault{\\quotedblbase}{%\n"
|
||||
" \\raisebox{-1.4ex}[1ex][.5ex]{\\textquotedblright}%\n"
|
||||
" \\penalty10000\\hskip0em\\relax%\n"
|
||||
"}";
|
||||
|
||||
string const quotesinglbase_def =
|
||||
"\\ProvideTextCommandDefault{\\quotesinglbase}{%\n"
|
||||
" \\raisebox{-1.4ex}[1ex][.5ex]{\\textquoteright}%\n"
|
||||
" \\penalty10000\\hskip0em\\relax%\n"
|
||||
"}";
|
||||
|
||||
string const guillemotleft_def =
|
||||
"\\ProvideTextCommandDefault{\\guillemotleft}{%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'50\\kern-.15em\\char'50}%\n"
|
||||
"\\penalty10000\\hskip0pt\\relax%\n"
|
||||
"}";
|
||||
|
||||
string const guillemotright_def =
|
||||
"\\ProvideTextCommandDefault{\\guillemotright}{%\n"
|
||||
" \\penalty10000\\hskip0pt%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'51\\kern-.15em\\char'51}%\n"
|
||||
"}";
|
||||
|
||||
string const guilsinglleft_def =
|
||||
"\\ProvideTextCommandDefault{\\guilsinglleft}{%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'50}%\n"
|
||||
" \\penalty10000\\hskip0pt\\relax%\n"
|
||||
"}";
|
||||
|
||||
string const guilsinglright_def =
|
||||
"\\ProvideTextCommandDefault{\\guilsinglright}{%\n"
|
||||
" \\penalty10000\\hskip0pt%\n"
|
||||
" {\\usefont{U}{lasy}{m}{n}\\char'51}%\n"
|
||||
"}";
|
||||
|
||||
string const paragraphleftindent_def =
|
||||
"\\newenvironment{LyXParagraphLeftIndent}[1]%\n"
|
||||
"{\n"
|
||||
" \\begin{list}{}{%\n"
|
||||
" \\setlength{\\topsep}{0pt}%\n"
|
||||
" \\addtolength{\\leftmargin}{#1}\n"
|
||||
// ho hum, yet more things commented out with no hint as to why they
|
||||
// weren't just removed
|
||||
// "%% \\addtolength{\\leftmargin}{#1\\textwidth}\n"
|
||||
// "%% \\setlength{\\textwidth}{#2\\textwidth}\n"
|
||||
// "%% \\setlength\\listparindent\\parindent%\n"
|
||||
// "%% \\setlength\\itemindent\\parindent%\n"
|
||||
" \\setlength{\\parsep}{0pt plus 1pt}%\n"
|
||||
" }\n"
|
||||
" \\item[]\n"
|
||||
"}\n"
|
||||
"{\\end{list}}\n";
|
||||
|
||||
string const floatingfootnote_def =
|
||||
"%% Special footnote code from the package 'stblftnt.sty'\n"
|
||||
"%% Author: Robin Fairbairns -- Last revised Dec 13 1996\n"
|
||||
"\\let\\SF@@footnote\\footnote\n"
|
||||
"\\def\\footnote{\\ifx\\protect\\@typeset@protect\n"
|
||||
" \\expandafter\\SF@@footnote\n"
|
||||
" \\else\n"
|
||||
" \\expandafter\\SF@gobble@opt\n"
|
||||
" \\fi\n"
|
||||
"}\n"
|
||||
"\\expandafter\\def\\csname SF@gobble@opt \\endcsname{\\@ifnextchar[%]\n"
|
||||
" \\SF@gobble@twobracket\n"
|
||||
" \\@gobble\n"
|
||||
"}\n"
|
||||
"\\edef\\SF@gobble@opt{\\noexpand\\protect\n"
|
||||
" \\expandafter\\noexpand\\csname SF@gobble@opt \\endcsname}\n"
|
||||
"\\def\\SF@gobble@twobracket[#1]#2{}\n";
|
||||
|
||||
string const boldsymbol_def =
|
||||
"%% Bold symbol macro for standard LaTeX users\n"
|
||||
"\\providecommand{\\boldsymbol}[1]{\\mbox{\\boldmath $#1$}}\n";
|
||||
|
||||
string const binom_def =
|
||||
"%% Binom macro for standard LaTeX users\n"
|
||||
"\\newcommand{\\binom}[2]{{#1 \\choose #2}}\n";
|
||||
|
||||
string const mathcircumflex_def =
|
||||
"%% For printing a cirumflex inside a formula\n"
|
||||
"\\newcommand{\\mathcircumflex}[0]{\\mbox{\\^{}}}\n";
|
||||
|
||||
string const tabularnewline_def =
|
||||
"%% Because html converters don't know tabularnewline\n"
|
||||
"\\providecommand{\\tabularnewline}{\\\\}\n";
|
||||
|
||||
string const lyxgreyedout_def =
|
||||
"%% The greyedout annotation environment\n"
|
||||
"\\newenvironment{lyxgreyedout}{\\textcolor[gray]{0.8}\\bgroup}{\\egroup}\n";
|
||||
|
||||
// We want to omit the file extension for includegraphics, but this does not
|
||||
// work when the filename contains other dots.
|
||||
// Idea from http://www.tex.ac.uk/cgi-bin/texfaq2html?label=unkgrfextn
|
||||
string const lyxdot_def =
|
||||
"%% A simple dot to overcome graphicx limitations\n"
|
||||
"\\newcommand{\\lyxdot}{.}\n";
|
||||
|
||||
|
||||
} // namespace lyx
|
@ -1,64 +0,0 @@
|
||||
// -*- C++ -*-
|
||||
/**
|
||||
* \file lyx_sty.h
|
||||
* This file is part of LyX, the document processor.
|
||||
* Licence details can be found in the file COPYING.
|
||||
*
|
||||
* \author Lars Gullik Bjønnes
|
||||
*
|
||||
* Full author contact details are available in file CREDITS.
|
||||
*
|
||||
* A number of LaTeX command definitions for various
|
||||
* things. The name of this file is a holdover from the
|
||||
* days of yore.
|
||||
*/
|
||||
|
||||
#ifndef LYX_STY_H
|
||||
#define LYX_STY_H
|
||||
|
||||
#include <string>
|
||||
|
||||
|
||||
namespace lyx {
|
||||
|
||||
///
|
||||
extern std::string const lyx_def;
|
||||
///
|
||||
extern std::string const lyxline_def;
|
||||
///
|
||||
extern std::string const noun_def;
|
||||
///
|
||||
extern std::string const lyxarrow_def;
|
||||
///
|
||||
extern std::string const quotedblbase_def;
|
||||
///
|
||||
extern std::string const quotesinglbase_def;
|
||||
///
|
||||
extern std::string const guillemotleft_def;
|
||||
///
|
||||
extern std::string const guillemotright_def;
|
||||
///
|
||||
extern std::string const guilsinglleft_def;
|
||||
///
|
||||
extern std::string const guilsinglright_def;
|
||||
///
|
||||
extern std::string const paragraphleftindent_def;
|
||||
///
|
||||
extern std::string const floatingfootnote_def;
|
||||
///
|
||||
extern std::string const boldsymbol_def;
|
||||
///
|
||||
extern std::string const binom_def;
|
||||
///
|
||||
extern std::string const mathcircumflex_def;
|
||||
///
|
||||
extern std::string const tabularnewline_def;
|
||||
///
|
||||
extern std::string const lyxgreyedout_def;
|
||||
///
|
||||
extern std::string const lyxdot_def;
|
||||
|
||||
|
||||
} // namespace lyx
|
||||
|
||||
#endif // LYX_STY_H
|
Loading…
x
Reference in New Issue
Block a user