// -*- C++ -*-
/* This file is part of*
- * ======================================================
+ * ======================================================
*
* LyX, The Document Processor
*
- * Copyright (C) 1995 Matthias Ettrich
- * 1996-1998 LyX Team
+ * Copyright 1995 Matthias Ettrich
+ * Copyright 1996-2000 the LyX Team.
*
- *======================================================*/
+ * ====================================================== */
-#ifndef _INSET_INDEX_H
-#define _INSET_INDEX_H
+#ifndef INSET_INDEX_H
+#define INSET_INDEX_H
#ifdef __GNUG__
#pragma interface
#include "insetcommand.h"
-class Buffer;
struct LaTeXFeatures;
-// Created by Lgb 970227
-
-
/** Used to insert index labels
*/
-class InsetIndex: public InsetCommand {
+class InsetIndex : public InsetCommand {
public:
///
- InsetIndex(): InsetCommand("index") {;}
- ///
- InsetIndex(string const & key);
+ InsetIndex(InsetCommandParams const &);
///
- ~InsetIndex();
- ///
- Inset *Clone() { return new InsetIndex(contents);}
+ Inset * Clone(Buffer const &) const {
+ return new InsetIndex(params());
+ }
///
- void Edit(int, int);
+ string const getScreenLabel() const;
///
- unsigned char Editable() const
- {
- return 1;
- }
+ EDITABLE Editable() const { return IS_EDITABLE; }
///
- string getScreenLabel() const;
+ void Edit(BufferView *, int, int, unsigned int);
};
-class InsetPrintIndex: public InsetCommand {
+class InsetPrintIndex : public InsetCommand {
public:
///
- InsetPrintIndex();
+ InsetPrintIndex(InsetCommandParams const &);
///
- InsetPrintIndex(Buffer*);
- ///
- ~InsetPrintIndex();
+ Inset * Clone(Buffer const &) const {
+ return new InsetPrintIndex(params());
+ }
/// Updates needed features for this inset.
- void Validate(LaTeXFeatures &features) const;
+ void Validate(LaTeXFeatures & features) const;
///
- void Edit(int, int){;}
+ void Edit(BufferView *, int, int, unsigned int) {}
///
- unsigned char Editable() const{
- return 1;
- }
+ EDITABLE Editable() const{ return NOT_EDITABLE; }
///
- bool Display() const { return true; }
+ bool display() const { return true; }
///
Inset::Code LyxCode() const;
///
- string getScreenLabel() const;
-private:
- ///
- Buffer *owner;
-};
-
-// this was shifted here rather than a separate
-// file because its little and only need by
-// insetindex.C and lyx_gui_misc.C ARRae 981020
-struct FD_index_form {
- FL_FORM *index_form;
- FL_OBJECT *key;
- void *vdata;
- long ldata;
+ string const getScreenLabel() const;
};
-extern FD_index_form *index_form;
#endif