diff --git a/src/kde/kioslave/recoll/htmlif.cpp b/src/kde/kioslave/recoll/htmlif.cpp
index e65347ea..c01a2c6a 100644
--- a/src/kde/kioslave/recoll/htmlif.cpp
+++ b/src/kde/kioslave/recoll/htmlif.cpp
@@ -1,5 +1,5 @@
#ifndef lint
-static char rcsid[] = "@(#$Id: htmlif.cpp,v 1.8 2008-12-08 14:34:50 dockes Exp $ (C) 2005 J.F.Dockes";
+static char rcsid[] = "@(#$Id: htmlif.cpp,v 1.9 2008-12-08 17:43:32 dockes Exp $ (C) 2005 J.F.Dockes";
#endif
/*
* This program is free software; you can redistribute it and/or modify
@@ -97,12 +97,11 @@ const string& RecollKioPager::parFormat()
str <<
""
"%R %S "
- "Open ";
- str << "Preview
";
- str <<
- "%T
"
- "%M %D %U
"
- "%A %K";
+ "Preview " <<
+ "Open
" <<
+ "%T
"
+ "%M %D %U
"
+ "%A %K";
return parformat = str.str();
}
@@ -206,20 +205,29 @@ void RecollProtocol::queryDetails()
data(array);
}
+
class PlainToRichKio : public PlainToRich {
public:
- PlainToRichKio(bool inputhtml = false) : PlainToRich(inputhtml) {
+ PlainToRichKio(const string& nm, bool inputhtml = false)
+ : PlainToRich(inputhtml) , m_name(nm)
+ {
}
virtual ~PlainToRichKio() {}
virtual string header() {
if (m_inputhtml) {
return snull;
} else {
- return string("
"); + return + string("
" + "");
}
}
virtual string startMatch() {return string("");}
virtual string endMatch() {return string("");}
+ const string &m_name;
};
void RecollProtocol::showPreview(const Rcl::Doc& doc)
@@ -259,8 +267,8 @@ void RecollProtocol::showPreview(const Rcl::Doc& doc)
mimeType("text/html");
- PlainToRichKio ptr;
- ptr.set_inputhtml(!fdoc.mimetype.compare("text/html"));
+ string fname = path_getsimple(doc.url).c_str();
+ PlainToRichKio ptr(fname, !fdoc.mimetype.compare("text/html"));
list