mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-12 22:14:35 +00:00
1e947e3a18
Add a new layout syntax CiteEngine to define the citation commands available for a given citation engine. Also extend the CiteFormat syntax to allow more customization. This mechanism, previously used to produce bibliography entries in the citation GUI based on the BibTeX entrytype, is now also used to produce the textual labels for citation insets in the buffer view. Thus citation styles are almost completely customizable by modules. Modules for the basic, jurabib and natbib engines are implemented. Layout format incremented to 37. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@40820 a592a061-630c-0410-9148-cb99ea01b6c8
50 lines
883 B
C++
50 lines
883 B
C++
// -*- C++ -*-
|
|
/**
|
|
* \file Citation.h
|
|
* This file is part of LyX, the document processor.
|
|
* Licence details can be found in the file COPYING.
|
|
*
|
|
* \author Herbert Voß
|
|
*
|
|
* Full author contact details are available in file CREDITS.
|
|
*/
|
|
|
|
#ifndef CITATION_H
|
|
#define CITATION_H
|
|
|
|
#include <string>
|
|
|
|
namespace lyx {
|
|
|
|
class Buffer;
|
|
|
|
|
|
enum CiteEngineType {
|
|
ENGINE_TYPE_AUTHORYEAR = 1,
|
|
ENGINE_TYPE_NUMERICAL = 2,
|
|
};
|
|
|
|
|
|
class CitationStyle
|
|
{
|
|
public:
|
|
///
|
|
CitationStyle() : cmd("cite"), forceUpperCase(false), fullAuthorList(false),
|
|
textAfter(false), textBefore(false) {}
|
|
|
|
/// the LaTeX command
|
|
std::string cmd;
|
|
/// upper casing author prefixes (van -> Van)
|
|
bool forceUpperCase;
|
|
/// expanding the full author list
|
|
bool fullAuthorList;
|
|
/// supports text after the citation
|
|
bool textAfter;
|
|
/// supports text before the citation
|
|
bool textBefore;
|
|
};
|
|
|
|
} // namespace lyx
|
|
|
|
#endif
|