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"
|
|
|
|
|
1999-11-24 22:14:46 +00:00
|
|
|
class InsetLabel : public InsetCommand {
|
1999-09-27 18:44:28 +00:00
|
|
|
public:
|
|
|
|
///
|
2000-08-04 13:12:30 +00:00
|
|
|
InsetLabel(InsetCommandParams const &);
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
2000-10-10 11:50:43 +00:00
|
|
|
Inset * Clone(Buffer const &) const { return new InsetLabel(params()); }
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
2000-09-14 17:53:12 +00:00
|
|
|
string const getScreenLabel() const { return getContents(); }
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
2000-05-19 16:46:01 +00:00
|
|
|
EDITABLE Editable() const { return IS_EDITABLE; }
|
|
|
|
///
|
2000-08-04 13:12:30 +00:00
|
|
|
Inset::Code LyxCode() const { return Inset::LABEL_CODE; }
|
|
|
|
///
|
2000-05-19 16:46:01 +00:00
|
|
|
void Edit(BufferView *, int, int, unsigned int);
|
1999-09-27 18:44:28 +00:00
|
|
|
///
|
2000-09-14 17:53:12 +00:00
|
|
|
std::vector<string> const getLabelList() const;
|
2000-08-04 13:12:30 +00:00
|
|
|
///
|
2000-07-15 23:51:46 +00:00
|
|
|
int Latex(Buffer const *, std::ostream &,
|
|
|
|
bool fragile, bool free_spc) const;
|
2000-03-06 02:42:40 +00:00
|
|
|
///
|
2000-09-27 13:52:39 +00:00
|
|
|
int Ascii(Buffer const *, std::ostream &, int linelen) const;
|
2000-04-24 20:58:23 +00:00
|
|
|
///
|
2000-06-12 11:27:15 +00:00
|
|
|
int Linuxdoc(Buffer const *, std::ostream &) const;
|
2000-03-06 02:42:40 +00:00
|
|
|
///
|
2000-06-12 11:27:15 +00:00
|
|
|
int DocBook(Buffer const *, std::ostream &) const;
|
1999-09-27 18:44:28 +00:00
|
|
|
private:
|
|
|
|
/// This function escapes 8-bit characters
|
2000-09-14 17:53:12 +00:00
|
|
|
string const escape(string const &) const;
|
1999-09-27 18:44:28 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|