]> git.lyx.org Git - features.git/commitdiff
Fixed cursor position in minipages and small draw-fix in insettext.
authorJürgen Vigna <jug@sad.it>
Fri, 23 Mar 2001 10:39:16 +0000 (10:39 +0000)
committerJürgen Vigna <jug@sad.it>
Fri, 23 Mar 2001 10:39:16 +0000 (10:39 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@1812 a592a061-630c-0410-9148-cb99ea01b6c8

po/POTFILES.in
src/insets/ChangeLog
src/insets/insetcollapsable.C
src/insets/insettext.C

index d6b80435201623eef4dbe172b0f31b5bd4e3b40a..b864e7206ac40d919630c045d5039e63cc05fd45 100644 (file)
@@ -69,10 +69,15 @@ src/frontends/qt2/FileDialog.C
 src/frontends/qt2/FormCharacter.C
 src/frontends/qt2/FormCitation.C
 src/frontends/qt2/FormCopyright.C
+src/frontends/qt2/FormDocument.C
+src/frontends/qt2/FormIndex.C
 src/frontends/qt2/FormParagraph.C
 src/frontends/qt2/FormPrint.C
+src/frontends/qt2/FormRef.C
 src/frontends/qt2/FormSearch.C
 src/frontends/qt2/FormTabularCreate.C
+src/frontends/qt2/FormToc.C
+src/frontends/qt2/FormUrl.C
 src/frontends/qt2/paragraphdlgimpl.C
 src/frontends/qt2/tabularcreatedlgimpl.C
 src/frontends/xforms/combox.C
index 8e232300f42168c7dcc173860ce99c3f778d626a..cd96552f526f7f45b56d15ff7209bda8e162818c 100644 (file)
@@ -1,3 +1,12 @@
+2001-03-23  Juergen Vigna  <jug@sad.it>
+
+       * insettext.C (draw): force a FULL update if cleared == true.
+
+       * insetcollapsable.C (draw): Lars forgotten entry for changing this
+       routine to draw the minipages on its position-flag.
+       (InsetInInsetY): give back the right y position, because of minipage
+       position-flag.
+
 2001-03-23  José Abílio Matos  <jamatos@fep.up.pt>
 
        * insetfloat.h
index a359a94972b88c77770f0a5265437e2c89f6a169..2802e0507d64b53bb3ed1dbdeac1b054aa4fd37e 100644 (file)
@@ -199,25 +199,15 @@ void InsetCollapsable::draw(BufferView * bv, LyXFont const & f,
        cleared = true;
     }
 
-    // not needed if collapsed
     top_x = int(x);
     top_baseline = baseline;
 
-#if 0
-    draw_collapsed(pain, f, baseline, x);
-    inset->draw(bv, f, baseline, x, cleared);
-#else
-#warning Jürgen, can you have a look at this? (Lgb)
-    // the intention is quite clear if you set the positon in a minipage you
-    // want the minipage drawn according to that. but as you can see the
-    // cursor is wrongly placed.
     draw_collapsed(pain, f,
                   baseline - ascent(bv, f) + ascent_collapsed(pain, f),
                   x);
-    inset->draw(bv, f,
+    inset->draw(bv, f, 
                baseline - ascent(bv, f) + ascent_collapsed(pain, f),
                x, cleared);
-#endif
     need_update = NONE;
 }
 
@@ -402,7 +392,7 @@ bool InsetCollapsable::UpdateInsetInInset(BufferView * bv, Inset *in)
 
 unsigned int InsetCollapsable::InsetInInsetY()
 {
-    return inset->InsetInInsetY();
+    return inset->InsetInInsetY() - (top_baseline - inset->y());
 }
 
 
index c887bc739962216b1b3cd257b4d0f3ab40ca928e..6c2c89ec3f60f029cfe29f4460cfbaef7201e321 100644 (file)
@@ -352,6 +352,8 @@ void InsetText::draw(BufferView * bv, LyXFont const & f,
        bv->text->status = LyXText::CHANGED_IN_DRAW;
        return;
     }
+    if (cleared)
+       need_update = FULL;
 
     top_baseline = baseline;
     top_y = baseline - ascent(bv, f);