mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-26 03:11:59 +00:00
- Dump the inset position cache as well
- More debugging printing stuff git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15441 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
c908d743a5
commit
6ac15c5bb9
@ -368,6 +368,8 @@ bool BufferView::update(Update::flags flags)
|
||||
if (!buffer_)
|
||||
return false;
|
||||
|
||||
lyxerr[Debug::WORKAREA] << "BufferView::update" << std::endl;
|
||||
|
||||
// Update macro store
|
||||
buffer_->buildMacros();
|
||||
|
||||
|
@ -76,6 +76,13 @@ CoordCache::dump() const {
|
||||
lyxerr << "\" has point " << p.x_ << "," << p.y_ << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
lyxerr << "InsetCache contains:" << std::endl;
|
||||
for (CoordCacheBase<InsetBase>::cache_type::const_iterator i = getInsets().getData().begin(); i != getInsets().getData().end(); ++i) {
|
||||
InsetBase const * inset = (*i).first;
|
||||
Point p = (*i).second;
|
||||
lyxerr << "Inset " << inset << "(" << inset->getInsetName() << ") has point " << p.x_ << "," << p.y_ << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace lyx
|
||||
|
@ -95,6 +95,9 @@ private:
|
||||
|
||||
typedef std::map<T const *, Point> cache_type;
|
||||
cache_type data_;
|
||||
|
||||
public:
|
||||
cache_type const & getData() const { return data_; }
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -96,6 +96,7 @@ void LyXView::setWorkArea(WorkArea * work_area)
|
||||
|
||||
void LyXView::redrawWorkArea()
|
||||
{
|
||||
lyxerr[Debug::WORKAREA] << "redrawWorkArea" << std::endl;
|
||||
work_area_->redraw();
|
||||
updateStatusBar();
|
||||
}
|
||||
|
@ -216,7 +216,7 @@ void WorkArea::redraw()
|
||||
greyed_out_ = false;
|
||||
getPainter().start();
|
||||
paintText(*buffer_view_, vi, getPainter());
|
||||
lyxerr[Debug::DEBUG] << "Redraw screen" << endl;
|
||||
lyxerr[Debug::WORKAREA] << "WorkArea::redraw screen" << endl;
|
||||
int const ymin = std::max(vi.y1, 0);
|
||||
int const ymax =
|
||||
( vi.p2 < vi.size - 1 ? vi.y2 : height() );
|
||||
|
@ -247,7 +247,7 @@ InsetBase * InsetText::editXY(LCursor & cur, int x, int y)
|
||||
|
||||
void InsetText::doDispatch(LCursor & cur, FuncRequest & cmd)
|
||||
{
|
||||
lyxerr[Debug::DEBUG] << BOOST_CURRENT_FUNCTION
|
||||
lyxerr[Debug::ACTION] << BOOST_CURRENT_FUNCTION
|
||||
<< " [ cmd.action = "
|
||||
<< cmd.action << ']' << endl;
|
||||
setViewCache(&cur.bv());
|
||||
|
@ -958,6 +958,9 @@ Row const & LyXText::getRowNearY(int y, pit_type pit) const
|
||||
// sets cursor recursively descending into nested editable insets
|
||||
InsetBase * LyXText::editXY(LCursor & cur, int x, int y)
|
||||
{
|
||||
if (lyxerr.debugging(Debug::WORKAREA)) {
|
||||
bv()->coordCache().dump();
|
||||
}
|
||||
pit_type pit = getPitNearY(y);
|
||||
BOOST_ASSERT(pit != -1);
|
||||
Row const & row = getRowNearY(y, pit);
|
||||
|
Loading…
Reference in New Issue
Block a user