#include "LyXView.h"
#include "minibuffer.h"
#include "lyx_gui_misc.h"
+#include "lyx_cb.h"
using std::map;
using std::vector;
using std::queue;
+using std::pair;
+using std::sort;
using std::stack;
-
-extern void ShowMessage(Buffer * buf,
- string const & msg1,
- string const & msg2 = string(),
- string const & msg3 = string(), int delay = 6);
+using std::endl;
//////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////
-Format::Format(string const & n) : name(n), in_degree(0)
+Format::Format(string const & n)
+ : name(n), in_degree(0)
{
struct Item {
char const * name;
}
}
+
void Formats::Add(string const & name)
{
if (formats.find(name) == formats.end())
formats[name] = Format(name);
}
+
void Formats::SetViewer(string const & name, string const & command)
{
Add(name);
return 0;
}
-string Formats::PrettyName(string const & name)
+string const Formats::PrettyName(string const & name)
{
-
string format;
Converter::SplitFormat(name, format);
Format * f = GetFormat(format);
return format;
}
+
//////////////////////////////////////////////////////////////////////////////
void Converter::Add(string const & from, string const & to,
string const & command, string const & flags)
++Formats::GetFormat(to)->in_degree;
}
-vector< pair<string,string> >
+
+vector< pair<string,string> > const
Converter::GetReachable(string const & from, bool only_viewable)
{
vector< pair<string,string> > result;
string const & to_format)
{
- string using_format, format;
- using_format = SplitFormat(to_format, format);
+ string format;
+ string using_format = SplitFormat(to_format, format);
string from_format = GetExtension(from_file);
if (from_format == format)
return true;
}
-string Converter::SplitFormat(string const & str, string & format)
+string const Converter::SplitFormat(string const & str, string & format)
{
string using_format = split(str, format, ':');
if (format.empty())
return using_format;
}
+
bool Converter::runLaTeX(Buffer * buffer, string const & command)
{