1999-09-27 18:44:28 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
/* This file is part of*
|
|
|
|
* ======================================================
|
|
|
|
*
|
|
|
|
* LyX, The Document Processor
|
|
|
|
*
|
1999-11-04 01:40:20 +00:00
|
|
|
* Copyright 1995 Matthias Ettrich
|
2000-03-16 04:29:22 +00:00
|
|
|
* Copyright 1995-2000 The LyX Team
|
1999-09-27 18:44:28 +00:00
|
|
|
*
|
1999-11-15 10:58:38 +00:00
|
|
|
* ====================================================== */
|
1999-09-27 18:44:28 +00:00
|
|
|
|
1999-11-04 01:40:20 +00:00
|
|
|
#ifndef INSET_LABEL_H
|
|
|
|
#define INSET_LABEL_H
|
1999-09-27 18:44:28 +00:00
|
|
|
|
|
|
|
#ifdef __GNUG__
|
|
|
|
#pragma interface
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include "insetcommand.h"
|
|
|
|
#include "LString.h"
|
|
|
|
|
|
|
|
///
|
1999-11-24 22:14:46 +00:00
|
|
|
class InsetLabel : public InsetCommand {
|
1999-09-27 18:44:28 +00:00
|
|
|
public:
|
|
|
|
///
|
2000-04-08 17:02:02 +00:00
|
|
|
explicit
|
1999-10-02 16:21:10 +00:00
|
|
|
InsetLabel(string const & cmd);
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
1999-11-04 01:40:20 +00:00
|
|
|
InsetLabel() : InsetCommand("label") {}
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
1999-11-24 22:14:46 +00:00
|
|
|
Inset * Clone() const;
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
|
|
|
Inset::Code LyxCode() const { return Inset::LABEL_CODE; }
|
|
|
|
///
|
|
|
|
int GetNumberOfLabels() const;
|
|
|
|
///
|
1999-10-02 16:21:10 +00:00
|
|
|
string getLabel(int) const;
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
1999-10-02 16:21:10 +00:00
|
|
|
string getScreenLabel() const { return getContents(); }
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
2000-03-08 13:52:57 +00:00
|
|
|
EDITABLE Editable() const { return NOT_EDITABLE; }
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
2000-04-04 00:19:15 +00:00
|
|
|
int Latex(std::ostream &, signed char fragile, bool free_spc) const;
|
2000-03-06 02:42:40 +00:00
|
|
|
///
|
2000-04-04 00:19:15 +00:00
|
|
|
int Linuxdoc(std::ostream &) const;
|
2000-03-06 02:42:40 +00:00
|
|
|
///
|
2000-04-04 00:19:15 +00:00
|
|
|
int DocBook(std::ostream &) const;
|
1999-09-27 18:44:28 +00:00
|
|
|
private:
|
|
|
|
/// This function escapes 8-bit characters
|
1999-10-02 16:21:10 +00:00
|
|
|
string escape(string const &) const;
|
1999-09-27 18:44:28 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|