mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
Changes to make RH-7.3 be able to run lyx.
Also changes to make gcc 3.1 compiled lyx exit cleanly after above changes. Move operator== out out InsetCommandParams. Change some signals in GraphicsImage to function instead. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4535 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
46880e2b9b
commit
de236c41d8
@ -8,7 +8,6 @@ src/converter.C
|
||||
src/CutAndPaste.C
|
||||
src/debug.C
|
||||
src/exporter.C
|
||||
src/ext_l10n.h
|
||||
src/FloatList.C
|
||||
src/frontends/controllers/biblio.C
|
||||
src/frontends/controllers/ButtonController.h
|
||||
|
@ -1,3 +1,9 @@
|
||||
2002-07-04 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* screen.C (SplashScreen): we change
|
||||
(topCursorVisible): ws change
|
||||
(greyOut): divide by 2 instead of multiplying with 0.5
|
||||
|
||||
2002-07-02 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* Dialogs.h: remove static from redrawGUI and
|
||||
|
@ -1,3 +1,7 @@
|
||||
2002-07-04 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* ControlBibtex.C (applyParamsToInset): ws change
|
||||
|
||||
2002-06-27 Juergen Spitzmueller <j.spitzmueller@gmx.de>
|
||||
|
||||
* ControlInclude.C: Add warning if absolute path name and
|
||||
|
@ -49,7 +49,7 @@ void ControlBibtex::applyParamsToInset()
|
||||
|
||||
// We need to do a redraw because the maximum
|
||||
// InsetBibKey width could have changed
|
||||
#warning are you sure you need this repaint() ?
|
||||
#warning are you sure you need this repaint() ?
|
||||
lv_.view()->repaint();
|
||||
lv_.view()->fitCursor();
|
||||
}
|
||||
|
@ -94,8 +94,8 @@ SplashScreen::SplashScreen()
|
||||
loader_.reset(file);
|
||||
// We aren't interested here in when the image is loaded.
|
||||
// If it isn't ready when we want it, then we ignore it.
|
||||
// loader_->statusChanged.connect(
|
||||
// boost::bind(&SplashScreen::statusChanged, this));
|
||||
// loader_->statusChanged.connect(
|
||||
// boost::bind(&SplashScreen::statusChanged, this));
|
||||
if (loader_.status() == grfx::WaitingToLoad)
|
||||
loader_.startLoading();
|
||||
}
|
||||
@ -189,8 +189,7 @@ unsigned int LyXScreen::topCursorVisible(LyXCursor const & cursor, int top_y)
|
||||
if (!row)
|
||||
return max(newtop, 0);
|
||||
|
||||
if (cursor.y() - row->baseline() + row->height()
|
||||
- top_y >= vheight) {
|
||||
if (cursor.y() - row->baseline() + row->height() - top_y >= vheight) {
|
||||
if (row->height() < vheight
|
||||
&& row->height() > vheight / 4) {
|
||||
newtop = cursor.y()
|
||||
@ -381,14 +380,14 @@ void LyXScreen::greyOut()
|
||||
int const w = splash_image->getWidth();
|
||||
int const h = splash_image->getHeight();
|
||||
|
||||
int x = 0.5 * (workarea().workWidth() - w);
|
||||
int y = 0.5 * (workarea().workHeight() - h);
|
||||
int x = (workarea().workWidth() - w) / 2;
|
||||
int y = (workarea().workHeight() - h) / 2;
|
||||
|
||||
workarea().getPainter().image(x, y, w, h, *splash_image);
|
||||
|
||||
string const & splash_text = splash.text();
|
||||
LyXFont const & splash_font = splash.font();
|
||||
|
||||
|
||||
x += 260;
|
||||
y += 265;
|
||||
|
||||
|
@ -1,13 +1,31 @@
|
||||
2002-07-04 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* lyx_gui.C (init_graphics): boost::function assign, not
|
||||
boost::signal connect.
|
||||
|
||||
* combox.C (Combox): what remove does is now done implicitly from
|
||||
XFormsView destructor.
|
||||
|
||||
* XMiniBuffer.C (peek_event): comment last arg to avoid warning.
|
||||
|
||||
* XFormsView.h: form_ is now a raw pointer not a scoped_ptr.
|
||||
|
||||
* XFormsView.C (XFormsView): hide and free form_
|
||||
(getForm): raw pointer return
|
||||
(create_form_form_main): raw pointer set
|
||||
|
||||
* Toolbar_pimpl.C (toolbarItem): whet clean does is now done
|
||||
implicitly from XFormsView destructor.
|
||||
|
||||
2002-07-04 André Pönitz <poenitz@gmx.net>
|
||||
|
||||
* FormInset.[Ch]: reduce #include depencies
|
||||
|
||||
|
||||
* guiapi.C: suppress compiler warning
|
||||
|
||||
2002-06-27 Juergen Spitzmueller <j.spitzmueller@gmx.de>
|
||||
|
||||
* FormInclude.C: Comment out unneeded and wrong update mechanism
|
||||
* FormInclude.C: Comment out unneeded and wrong update mechanism
|
||||
(related to bug #459)
|
||||
*forms/form_include.fd: define missing callbacks (bug #459)
|
||||
|
||||
|
@ -53,7 +53,9 @@ Toolbar::Pimpl::toolbarItem::toolbarItem()
|
||||
|
||||
Toolbar::Pimpl::toolbarItem::~toolbarItem()
|
||||
{
|
||||
clean();
|
||||
// It seems that now this is taken care of
|
||||
// in the XFormsView destructor. (Lgb)
|
||||
// clean();
|
||||
}
|
||||
|
||||
|
||||
|
@ -72,7 +72,11 @@ XFormsView::XFormsView(int width, int height)
|
||||
}
|
||||
|
||||
|
||||
XFormsView::~XFormsView() {}
|
||||
XFormsView::~XFormsView()
|
||||
{
|
||||
fl_hide_form(form_);
|
||||
fl_free_form(form_);
|
||||
}
|
||||
|
||||
|
||||
/// Redraw the main form.
|
||||
@ -88,7 +92,7 @@ void XFormsView::redraw()
|
||||
|
||||
FL_FORM * XFormsView::getForm() const
|
||||
{
|
||||
return form_.get();
|
||||
return form_;
|
||||
}
|
||||
|
||||
|
||||
@ -133,7 +137,7 @@ void XFormsView::create_form_form_main(Dialogs & dia, int width, int height)
|
||||
*/
|
||||
{
|
||||
// the main form
|
||||
form_.reset(fl_bgn_form(FL_NO_BOX, width, height));
|
||||
form_ = fl_bgn_form(FL_NO_BOX, width, height);
|
||||
getForm()->u_vdata = this;
|
||||
FL_OBJECT * obj = fl_add_box(FL_FLAT_BOX, 0, 0, width, height, "");
|
||||
fl_set_object_color(obj, FL_MCOL, FL_MCOL);
|
||||
|
@ -65,6 +65,6 @@ private:
|
||||
/// makes the main form.
|
||||
void create_form_form_main(Dialogs & d, int width, int height);
|
||||
/// the main form.
|
||||
boost::scoped_ptr<FL_FORM> form_;
|
||||
FL_FORM * form_;
|
||||
};
|
||||
#endif
|
||||
|
@ -75,14 +75,15 @@ XMiniBuffer::~XMiniBuffer()
|
||||
}
|
||||
|
||||
|
||||
int XMiniBuffer::peek_event(FL_OBJECT * ob, int event, int key, XEvent * xev)
|
||||
int XMiniBuffer::peek_event(FL_OBJECT * ob, int event,
|
||||
int key, XEvent * /*xev*/)
|
||||
{
|
||||
#if 0
|
||||
if (dropdown_->isVisible()) {
|
||||
return dropdown_->peek(xev);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
switch (event) {
|
||||
case FL_UNFOCUS:
|
||||
messageMode();
|
||||
@ -98,7 +99,7 @@ int XMiniBuffer::peek_event(FL_OBJECT * ob, int event, int key, XEvent * xev)
|
||||
char const * tmp = fl_get_input(ob);
|
||||
input = tmp ? tmp : "";
|
||||
}
|
||||
|
||||
|
||||
|
||||
switch (key) {
|
||||
case XK_Down:
|
||||
|
@ -84,7 +84,8 @@ Combox::Combox(combox_type t)
|
||||
|
||||
Combox::~Combox()
|
||||
{
|
||||
remove();
|
||||
// This is now handled by the XFormsView destructor (Lgb)
|
||||
// remove();
|
||||
}
|
||||
|
||||
|
||||
|
@ -300,11 +300,11 @@ void lyx_gui::init_graphics()
|
||||
|
||||
#ifdef USE_XFORMS_IMAGE_LOADER
|
||||
// connect the image loader based on the xforms library
|
||||
Image::newImage.connect(boost::bind(&xformsImage::newImage));
|
||||
Image::loadableFormats.connect(boost::bind(&xformsImage::loadableFormats));
|
||||
Image::newImage = boost::bind(&xformsImage::newImage);
|
||||
Image::loadableFormats = boost::bind(&xformsImage::loadableFormats);
|
||||
#else
|
||||
// connect the image loader based on the XPM library
|
||||
Image::newImage.connect(boost::bind(&ImageXPM::newImage));
|
||||
Image::loadableFormats.connect(boost::bind(&ImageXPM::loadableFormats));
|
||||
Image::newImage = boost::bind(&ImageXPM::newImage);
|
||||
Image::loadableFormats = boost::bind(&ImageXPM::loadableFormats);
|
||||
#endif
|
||||
}
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-07-04 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* GraphicsImage.[Ch]: newImage and loadableFormats changed to
|
||||
boost::function from boost::signal.
|
||||
|
||||
2002-07-01 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
|
||||
|
||||
* GraphicsConverter.C (convert): do not use ChangeExtension
|
||||
@ -19,7 +24,7 @@
|
||||
grfx::Converter now represents a single conversion process.
|
||||
Thus grfx::CachItem now has a grfx::Converter * that is set when the
|
||||
conversion is initiated and destroyed on completion.
|
||||
|
||||
|
||||
* GraphicsCache.[Ch]:
|
||||
* GraphicsCacheItem.[Ch]:
|
||||
* GraphicsConverter.[Ch]:
|
||||
@ -29,7 +34,7 @@
|
||||
so not only should we have a clean, minimal and well documented
|
||||
interface to these classes in the header files, but the class internals
|
||||
should be much clearer too.
|
||||
|
||||
|
||||
* Renamed classes
|
||||
grfx::GCache -> grfx::Cache,
|
||||
grfx::GCacheItem -> grfx::CacheItem,
|
||||
@ -80,15 +85,15 @@
|
||||
|
||||
2002-06-17 Herbert Voss <voss@lyx.org>
|
||||
|
||||
* GraphicsCachItem.C: (findTargetFormat)return xpm-format as a
|
||||
* GraphicsCachItem.C: (findTargetFormat)return xpm-format as a
|
||||
default when nothing different was found
|
||||
(convertToDisplayFormat): handle zipped files in the right way and
|
||||
choose always convert as a default converter when no other
|
||||
(convertToDisplayFormat): handle zipped files in the right way and
|
||||
choose always convert as a default converter when no other
|
||||
userdefined was found
|
||||
|
||||
|
||||
* GraphicsConverter.C: add more lyxerr comments and choose
|
||||
convert when no other userdefined converter was found
|
||||
|
||||
|
||||
2002-06-10 Herbert Voss <voss@lyx.org>
|
||||
|
||||
* GraphicsImageXPM.C (convertTo7chars): get another special color
|
||||
@ -97,20 +102,20 @@
|
||||
2002-06-12 John Levon <moz@compsoc.man.ac.uk>
|
||||
|
||||
* GraphicsCache.C: use right colormap incantation
|
||||
|
||||
|
||||
2002-06-12 John Levon <moz@compsoc.man.ac.uk>
|
||||
|
||||
* GraphicsCache.C: use lyx_gui namespace
|
||||
|
||||
* GraphicsImageXPM.C: back down to using xforms
|
||||
directly again
|
||||
|
||||
|
||||
2002-06-07 Angus Leeming <leeming@lyx.org>
|
||||
|
||||
Fixes needed to compile with Compaq cxx 6.5.
|
||||
* GraphicsConverter.h: forward declare class ConvProcess.
|
||||
|
||||
* GraphicsImageXPM.C:
|
||||
* GraphicsImageXPM.C:
|
||||
all c-library variables have been moved into namespace std.
|
||||
Wrap using std::xyz declarations inside a #ifndef CXX_GLOBAL_CSTD block.
|
||||
|
||||
|
@ -20,10 +20,11 @@ namespace grfx {
|
||||
|
||||
// This is to be connected to a function that will return a new
|
||||
// instance of a viable derived class.
|
||||
boost::signal0<Image::ImagePtr> Image::newImage;
|
||||
boost::function0<Image::ImagePtr> Image::newImage;
|
||||
|
||||
/// Return the list of loadable formats.
|
||||
boost::signal0<Image::FormatList> Image::loadableFormats;
|
||||
boost::function0<Image::FormatList> Image::loadableFormats;
|
||||
|
||||
|
||||
std::pair<unsigned int, unsigned int>
|
||||
Image::getScaledDimensions(Params const & params) const
|
||||
|
@ -25,7 +25,7 @@
|
||||
#include "LString.h"
|
||||
|
||||
#include <boost/shared_ptr.hpp>
|
||||
#include <boost/signals/signal0.hpp>
|
||||
#include <boost/function/function0.hpp>
|
||||
#include <boost/signals/signal1.hpp>
|
||||
|
||||
#include <X11/X.h> // for Pixmap :-(
|
||||
@ -48,12 +48,12 @@ public:
|
||||
*/
|
||||
typedef boost::shared_ptr<Image> ImagePtr;
|
||||
///
|
||||
static boost::signal0<ImagePtr> newImage;
|
||||
static boost::function0<ImagePtr> newImage;
|
||||
|
||||
/// Return the list of loadable formats.
|
||||
typedef std::vector<string> FormatList;
|
||||
///
|
||||
static boost::signal0<FormatList> loadableFormats;
|
||||
static boost::function0<FormatList> loadableFormats;
|
||||
|
||||
/// Must define default c-tor explicitly as we define a copy c-tor.
|
||||
Image() {}
|
||||
|
@ -1,3 +1,7 @@
|
||||
2002-07-04 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* insetcommandparams.[Ch] (operator=): move out of class
|
||||
(operator!): move out of class
|
||||
|
||||
2002-07-04 André Pönitz <poenitz@gmx.net>
|
||||
|
||||
|
@ -16,6 +16,11 @@
|
||||
#include "lyxlex.h"
|
||||
#include "debug.h"
|
||||
|
||||
#include "support/LOstream.h"
|
||||
|
||||
using std::ostream;
|
||||
using std::endl;
|
||||
|
||||
|
||||
InsetCommandParams::InsetCommandParams()
|
||||
{}
|
||||
@ -58,19 +63,6 @@ void InsetCommandParams::setFromString(string const & b)
|
||||
}
|
||||
|
||||
|
||||
bool InsetCommandParams::operator==(InsetCommandParams const & o) const
|
||||
{
|
||||
return cmdname == o.cmdname && contents == o.contents
|
||||
&& options == o.options;
|
||||
}
|
||||
|
||||
|
||||
bool InsetCommandParams::operator!=(InsetCommandParams const & o) const
|
||||
{
|
||||
return !(*this == o);
|
||||
}
|
||||
|
||||
|
||||
void InsetCommandParams::scanCommand(string const & cmd)
|
||||
{
|
||||
string tcmdname, toptions, tcontents;
|
||||
@ -172,3 +164,18 @@ string const InsetCommandParams::getCommand() const
|
||||
return s;
|
||||
}
|
||||
|
||||
|
||||
bool operator==(InsetCommandParams const & o1,
|
||||
InsetCommandParams const & o2)
|
||||
{
|
||||
return o1.getCmdName() == o2.getCmdName()
|
||||
&& o1.getContents() == o2.getContents()
|
||||
&& o1.getOptions() == o2.getOptions();
|
||||
}
|
||||
|
||||
|
||||
bool operator!=(InsetCommandParams const & o1,
|
||||
InsetCommandParams const & o2)
|
||||
{
|
||||
return !(o1 == o2);
|
||||
}
|
||||
|
@ -33,10 +33,6 @@ public:
|
||||
string const & c = string(),
|
||||
string const & o = string());
|
||||
///
|
||||
bool operator==(InsetCommandParams const &) const;
|
||||
///
|
||||
bool operator!=(InsetCommandParams const &) const;
|
||||
///
|
||||
void read(LyXLex &);
|
||||
/// Parse the command
|
||||
void scanCommand(string const &);
|
||||
@ -70,4 +66,12 @@ private:
|
||||
};
|
||||
|
||||
|
||||
///
|
||||
bool operator==(InsetCommandParams const &,
|
||||
InsetCommandParams const &);
|
||||
|
||||
///
|
||||
bool operator!=(InsetCommandParams const &,
|
||||
InsetCommandParams const &);
|
||||
|
||||
#endif
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-07-04 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* formulabase.C: ws changes
|
||||
* formula.C: ws changes
|
||||
|
||||
2002-07-01 Geof Piroux
|
||||
|
||||
* math_ex*.[Ch] et al: support for Mathematica as CAS backend
|
||||
@ -17,13 +22,13 @@
|
||||
2002-06-24 André Pönitz <poenitz@gmx.net>
|
||||
|
||||
* *.[Ch]: left over changes from Porto
|
||||
|
||||
|
||||
* math_gridinset.C (eolString): fix #456
|
||||
|
||||
2002-06-21 John Levon <moz@compsoc.man.ac.uk>
|
||||
|
||||
* formula.C: use repaint()
|
||||
|
||||
|
||||
2002-06-16 André Pönitz <poenitz@gmx.net>
|
||||
|
||||
* math_factory.C:
|
||||
|
@ -76,7 +76,7 @@ InsetFormula::InsetFormula(string const & data)
|
||||
{
|
||||
if (!data.size())
|
||||
return;
|
||||
if (!mathed_parse_normal(par_, data))
|
||||
if (!mathed_parse_normal(par_, data))
|
||||
lyxerr << "cannot interpret '" << data << "' as math\n";
|
||||
}
|
||||
|
||||
@ -279,7 +279,7 @@ InsetFormula::localDispatch(BufferView * bv, kb_action action,
|
||||
}
|
||||
|
||||
#warning FIXME: please check you really mean repaint() ... is it needed,
|
||||
#warning and if so, should it be update() instead ?
|
||||
#warning and if so, should it be update() instead ?
|
||||
if (!new_label.empty() && bv->ChangeRefsIfUnique(old_label, new_label))
|
||||
bv->repaint();
|
||||
|
||||
@ -382,7 +382,7 @@ bool InsetFormula::insetAllowed(Inset::Code code) const
|
||||
{
|
||||
return
|
||||
(code == Inset::LABEL_CODE && display())
|
||||
|| code == Inset::REF_CODE
|
||||
|| code == Inset::REF_CODE
|
||||
|| code == Inset::ERT_CODE;
|
||||
}
|
||||
|
||||
@ -440,7 +440,7 @@ void InsetFormula::statusChanged()
|
||||
{
|
||||
lyxerr << "### InsetFormula::statusChanged called!, status: "
|
||||
<< loader_->status() << "\n";
|
||||
if (loader_->status() == grfx::Ready)
|
||||
if (loader_->status() == grfx::Ready)
|
||||
view()->updateInset(this, false);
|
||||
else if (loader_->status() == grfx::WaitingToLoad)
|
||||
loader_->startLoading();
|
||||
@ -454,7 +454,7 @@ void InsetFormula::updatePreview()
|
||||
if (!lyxrc.preview)
|
||||
return;
|
||||
|
||||
// get LaTeX
|
||||
// get LaTeX
|
||||
ostringstream ls;
|
||||
WriteStream wi(ls, false, false);
|
||||
par_->write(wi);
|
||||
@ -505,4 +505,3 @@ void InsetFormula::updatePreview()
|
||||
loader_->startLoading();
|
||||
loader_->statusChanged.connect(boost::bind(&InsetFormula::statusChanged, this));
|
||||
}
|
||||
|
||||
|
@ -1030,7 +1030,7 @@ void mathDispatchInsertMatrix(BufferView * bv, string const & arg)
|
||||
if (!bv->available())
|
||||
return;
|
||||
InsetFormula * f = new InsetFormula(bv);
|
||||
if (openNewInset(bv, f)) {
|
||||
if (openNewInset(bv, f)) {
|
||||
f->mutate("simple");
|
||||
bv->theLockingInset()->localDispatch(bv, LFUN_INSERT_MATRIX, arg);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user