1999-09-27 18:44:28 +00:00
|
|
|
#include <config.h>
|
|
|
|
|
|
|
|
#ifdef __GNUG__
|
|
|
|
#pragma implementation
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include "insetindex.h"
|
2000-08-03 12:56:25 +00:00
|
|
|
#include "BufferView.h"
|
|
|
|
#include "LyXView.h"
|
|
|
|
#include "frontends/Dialogs.h"
|
1999-09-27 18:44:28 +00:00
|
|
|
#include "LaTeXFeatures.h"
|
2001-04-05 12:26:41 +00:00
|
|
|
#include "gettext.h"
|
1999-09-27 18:44:28 +00:00
|
|
|
|
2001-07-06 15:57:54 +00:00
|
|
|
InsetIndex::InsetIndex(InsetCommandParams const & p, bool)
|
2000-08-03 12:56:25 +00:00
|
|
|
: InsetCommand(p)
|
2000-07-15 23:51:46 +00:00
|
|
|
{}
|
1999-09-27 18:44:28 +00:00
|
|
|
|
|
|
|
|
2000-09-14 17:53:12 +00:00
|
|
|
string const InsetIndex::getScreenLabel() const
|
1999-09-27 18:44:28 +00:00
|
|
|
{
|
|
|
|
return _("Idx");
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-06-28 10:25:20 +00:00
|
|
|
void InsetIndex::edit(BufferView * bv, int, int, unsigned int)
|
1999-09-27 18:44:28 +00:00
|
|
|
{
|
2000-08-03 12:56:25 +00:00
|
|
|
bv->owner()->getDialogs()->showIndex( this );
|
1999-09-27 18:44:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-07-20 14:18:48 +00:00
|
|
|
void InsetIndex::edit(BufferView * bv, bool)
|
|
|
|
{
|
|
|
|
edit(bv, 0, 0, 0);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-07-23 09:11:14 +00:00
|
|
|
Inset::Code InsetIndex::lyxCode() const
|
|
|
|
{
|
|
|
|
return Inset::INDEX_CODE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-07-06 15:57:54 +00:00
|
|
|
InsetPrintIndex::InsetPrintIndex(InsetCommandParams const & p, bool)
|
2000-08-03 12:56:25 +00:00
|
|
|
: InsetCommand(p)
|
2000-07-15 23:51:46 +00:00
|
|
|
{}
|
1999-09-27 18:44:28 +00:00
|
|
|
|
2000-09-14 17:53:12 +00:00
|
|
|
string const InsetPrintIndex::getScreenLabel() const
|
1999-09-27 18:44:28 +00:00
|
|
|
{
|
2000-08-03 12:56:25 +00:00
|
|
|
return _("Index");
|
1999-09-27 18:44:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-06-28 10:25:20 +00:00
|
|
|
void InsetPrintIndex::validate(LaTeXFeatures & features) const
|
1999-09-27 18:44:28 +00:00
|
|
|
{
|
|
|
|
features.makeidx = true;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-06-28 10:25:20 +00:00
|
|
|
Inset::Code InsetPrintIndex::lyxCode() const
|
1999-09-27 18:44:28 +00:00
|
|
|
{
|
2001-07-23 09:11:14 +00:00
|
|
|
return Inset::INDEX_PRINT_CODE;
|
1999-09-27 18:44:28 +00:00
|
|
|
}
|