2001-03-06 14:07:14 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
|
|
|
|
#ifndef PARAGRAPHPARAMETERS_H
|
|
|
|
#define PARAGRAPHPARAMETERS_H
|
|
|
|
|
2001-07-27 20:27:56 +00:00
|
|
|
#ifdef __GNUG__
|
|
|
|
#pragma interface
|
|
|
|
#endif
|
|
|
|
|
2001-03-06 14:07:14 +00:00
|
|
|
#include "LString.h"
|
2002-05-24 10:39:34 +00:00
|
|
|
#include "ShareContainer.h"
|
2001-03-06 14:07:14 +00:00
|
|
|
#include "layout.h"
|
2001-08-03 18:28:11 +00:00
|
|
|
|
|
|
|
// Not yet... lyx 1.3.x or so
|
2002-05-22 12:33:02 +00:00
|
|
|
#define NO_PEXTRA_REALLY 1
|
2001-08-03 18:28:11 +00:00
|
|
|
|
2001-04-17 15:15:59 +00:00
|
|
|
#include "ParameterStruct.h"
|
2001-03-06 14:07:14 +00:00
|
|
|
|
|
|
|
class VSpace;
|
|
|
|
class Spacing;
|
2001-04-17 15:15:59 +00:00
|
|
|
|
2001-03-06 14:07:14 +00:00
|
|
|
|
|
|
|
///
|
|
|
|
class ParagraphParameters {
|
|
|
|
public:
|
|
|
|
///
|
|
|
|
ParagraphParameters();
|
|
|
|
///
|
|
|
|
void clear();
|
|
|
|
///
|
|
|
|
bool sameLayout(ParagraphParameters const &) const;
|
|
|
|
///
|
|
|
|
VSpace const & spaceTop() const;
|
|
|
|
///
|
|
|
|
void spaceTop(VSpace const &);
|
|
|
|
///
|
|
|
|
VSpace const & spaceBottom() const;
|
|
|
|
///
|
|
|
|
void spaceBottom(VSpace const &);
|
|
|
|
///
|
|
|
|
Spacing const & spacing() const;
|
|
|
|
///
|
|
|
|
void spacing(Spacing const &);
|
|
|
|
///
|
|
|
|
bool noindent() const;
|
|
|
|
///
|
|
|
|
void noindent(bool);
|
|
|
|
///
|
|
|
|
bool lineTop() const;
|
|
|
|
///
|
|
|
|
void lineTop(bool);
|
|
|
|
///
|
|
|
|
bool lineBottom() const;
|
|
|
|
///
|
|
|
|
void lineBottom(bool);
|
|
|
|
///
|
|
|
|
bool pagebreakTop() const;
|
|
|
|
///
|
|
|
|
void pagebreakTop(bool);
|
|
|
|
///
|
|
|
|
bool pagebreakBottom() const;
|
|
|
|
///
|
|
|
|
void pagebreakBottom(bool);
|
|
|
|
///
|
|
|
|
LyXAlignment align() const;
|
|
|
|
///
|
|
|
|
void align(LyXAlignment);
|
|
|
|
///
|
2001-06-25 00:06:33 +00:00
|
|
|
typedef ParameterStruct::depth_type depth_type;
|
2001-03-06 14:07:14 +00:00
|
|
|
///
|
2001-06-25 00:06:33 +00:00
|
|
|
depth_type depth() const;
|
|
|
|
///
|
|
|
|
void depth(depth_type);
|
2001-03-06 14:07:14 +00:00
|
|
|
///
|
|
|
|
bool startOfAppendix() const;
|
|
|
|
///
|
|
|
|
void startOfAppendix(bool);
|
|
|
|
///
|
|
|
|
bool appendix() const;
|
|
|
|
///
|
|
|
|
void appendix(bool);
|
|
|
|
///
|
|
|
|
string const & labelString() const;
|
|
|
|
///
|
|
|
|
void labelString(string const &);
|
|
|
|
///
|
|
|
|
string const & labelWidthString() const;
|
|
|
|
///
|
|
|
|
void labelWidthString(string const &);
|
2002-05-08 12:58:16 +00:00
|
|
|
///
|
|
|
|
LyXLength const & leftIndent() const;
|
|
|
|
///
|
|
|
|
void leftIndent(LyXLength const &);
|
|
|
|
///
|
2001-03-16 00:09:53 +00:00
|
|
|
#ifndef NO_PEXTRA_REALLY
|
2001-03-06 14:07:14 +00:00
|
|
|
///
|
|
|
|
int pextraType() const;
|
|
|
|
///
|
|
|
|
void pextraType(int);
|
|
|
|
///
|
|
|
|
string const & pextraWidth() const;
|
|
|
|
///
|
|
|
|
void pextraWidth(string const &);
|
|
|
|
///
|
|
|
|
string const & pextraWidthp() const;
|
|
|
|
///
|
|
|
|
void pextraWidthp(string const &);
|
|
|
|
///
|
|
|
|
int pextraAlignment() const;
|
|
|
|
///
|
|
|
|
void pextraAlignment(int);
|
|
|
|
///
|
|
|
|
bool pextraHfill() const;
|
|
|
|
///
|
|
|
|
void pextraHfill(bool);
|
|
|
|
///
|
|
|
|
bool pextraStartMinipage() const;
|
|
|
|
///
|
|
|
|
void pextraStartMinipage(bool);
|
2001-03-16 00:09:53 +00:00
|
|
|
#endif
|
2001-03-06 14:07:14 +00:00
|
|
|
private:
|
|
|
|
///
|
|
|
|
void set_from_struct(ParameterStruct const &);
|
|
|
|
///
|
|
|
|
boost::shared_ptr<ParameterStruct> param;
|
|
|
|
///
|
|
|
|
static ShareContainer<ParameterStruct> container;
|
|
|
|
};
|
2001-04-17 15:15:59 +00:00
|
|
|
|
|
|
|
|
|
|
|
inline
|
2001-06-25 00:06:33 +00:00
|
|
|
ParagraphParameters::depth_type ParagraphParameters::depth() const
|
2001-04-17 15:15:59 +00:00
|
|
|
{
|
|
|
|
return param->depth;
|
|
|
|
}
|
2001-03-06 14:07:14 +00:00
|
|
|
#endif
|