}
-CursorSlice::idx_type CursorSlice::idx() const
-{
- return idx_;
-}
-
-
-CursorSlice::idx_type & CursorSlice::idx()
-{
- return idx_;
-}
-
-
-CursorSlice::par_type CursorSlice::par() const
-{
- return par_;
-}
-
-
-CursorSlice::par_type & CursorSlice::par()
-{
- return par_;
-}
-
-
-CursorSlice::pos_type CursorSlice::pos() const
-{
- return pos_;
-}
-
-
-CursorSlice::pos_type & CursorSlice::pos()
-{
- return pos_;
-}
-
-
CursorSlice::pos_type CursorSlice::lastpos() const
{
BOOST_ASSERT(inset_);
}
-bool CursorSlice::boundary() const
-{
- return boundary_;
-}
-
-
-bool & CursorSlice::boundary()
-{
- return boundary_;
-}
-
-
CursorSlice::row_type CursorSlice::row() const
{
BOOST_ASSERT(asMathInset());
{
// access to the main lyx text must be handled in the cursor
BOOST_ASSERT(text());
- return *text()->getPar(par_);
+ return text()->getPar(par_);
}
{
// access to the main lyx text must be handled in the cursor
BOOST_ASSERT(text());
- return *text()->getPar(par_);
+ return text()->getPar(par_);
}
if (&p.inset() != &q.inset()) {
lyxerr << "can't compare cursor and anchor in different insets\n"
<< "p: " << p << '\n' << "q: " << q << endl;
- return true;
+ BOOST_ASSERT(false);
}
if (p.idx() != q.idx())
return p.idx() < q.idx();
}
+bool operator<=(CursorSlice const & p, CursorSlice const & q)
+{
+ return !(q < p);
+}
+
+
std::ostream & operator<<(std::ostream & os, CursorSlice const & item)
{
return os