Preview fiddling (preparing the way for mathed previews).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@8647 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Angus Leeming 2004-04-13 13:10:33 +00:00
parent b3eefc106e
commit 671aab6377
9 changed files with 32 additions and 9 deletions

View File

@ -1,3 +1,8 @@
2004-04-13 Angus Leeming <leeming@lyx.org>
* lyx_main.[Ch] (updateInset): pass it an InsetBase pointer rather
than an InsetOld one.
2004-04-12 Georg Baum <Georg.Baum@post.rwth-aachen.de>
* format.[Ch]: add editor to Format

View File

@ -1,3 +1,7 @@
2004-04-13 Angus Leeming <leeming@lyx.org>
* LyXView.[Ch] (updateInset): pass it an InsetBase pointer rather
than an InsetOld one.
2004-04-07 Alfredo Braunstein <abraunst@lyx.org>
@ -10,7 +14,7 @@
2004-04-05 Angus Leeming <leeming@lyx.org>
* Dialogs.h: remove redundant header file. Clean up comments.
* Dialogs.h: remove #included header file. Clean up comments.
2004-03-31 Angus Leeming <leeming@lyx.org>

View File

@ -193,7 +193,7 @@ void LyXView::dispatch(FuncRequest const & cmd)
}
Buffer const * const LyXView::updateInset(InsetOld const * inset) const
Buffer const * const LyXView::updateInset(InsetBase const * inset) const
{
Buffer const * buffer_ptr = 0;
if (inset) {

View File

@ -21,7 +21,7 @@
class Buffer;
class Toolbar;
class InsetOld;
class InsetBase;
class Intl;
class Menubar;
class ControlCommandBuffer;
@ -135,7 +135,7 @@ public:
/** redraw \c inset in all the BufferViews in which it is currently
* visible. If successful return a pointer to the owning Buffer.
*/
Buffer const * const updateInset(InsetOld const *) const;
Buffer const * const updateInset(InsetBase const *) const;
protected:
/// view of a buffer. Eventually there will be several.

View File

@ -1,3 +1,9 @@
2004-04-13 Angus Leeming <leeming@lyx.org>
* PreviewLoader.C (dumpPreamble):
* Previews.C (generateBufferPreviews): re-enable iteration over all
insets.
2004-02-21 Georg Baum <Georg.Baum@post.rwth-aachen.de>
* GraphicsCacheItem.C (convertToDisplayFormat): unzip zipped files

View File

@ -600,7 +600,11 @@ void PreviewLoader::Impl::dumpPreamble(ostream & os) const
<< "\n";
// Loop over the insets in the buffer and dump all the math-macros.
for (InsetIterator it(buffer_.inset()); it; ++it)
InsetBase & inset = buffer_.inset();
InsetIterator it = inset_iterator_begin(inset);
InsetIterator const end = inset_iterator_end(inset);
for (; it != end; ++it)
if (it->lyxCode() == InsetOld::MATHMACRO_CODE)
it->latex(buffer_, os, runparams);

View File

@ -83,7 +83,11 @@ void Previews::generateBufferPreviews(Buffer const & buffer) const
{
PreviewLoader & ploader = loader(buffer);
for (InsetIterator it(buffer.inset()); it; ++it)
InsetBase & inset = buffer.inset();
InsetIterator it = inset_iterator_begin(inset);
InsetIterator const end = inset_iterator_end(inset);
for (; it != end; ++it)
it->addPreview(ploader);
ploader.startLoading();

View File

@ -163,7 +163,7 @@ void LyX::addLyXView(boost::shared_ptr<LyXView> const & lyxview)
}
Buffer const * const LyX::updateInset(InsetOld const * inset) const
Buffer const * const LyX::updateInset(InsetBase const * inset) const
{
if (!inset)
return 0;

View File

@ -23,7 +23,7 @@
class Buffer;
class ErrorItem;
class InsetOld;
class InsetBase;
class LastFiles;
class LyXView;
class kb_keymap;
@ -47,7 +47,7 @@ public:
/** redraw \c inset in all the BufferViews in which it is currently
* visible. If successful return a pointer to the owning Buffer.
*/
Buffer const * const updateInset(InsetOld const *) const;
Buffer const * const updateInset(InsetBase const *) const;
private:
static boost::scoped_ptr<LyX> singleton_;