]> git.lyx.org Git - features.git/commitdiff
fix column width resize
authorJohn Levon <levon@movementarian.org>
Mon, 2 Jun 2003 16:40:38 +0000 (16:40 +0000)
committerJohn Levon <levon@movementarian.org>
Mon, 2 Jun 2003 16:40:38 +0000 (16:40 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7086 a592a061-630c-0410-9148-cb99ea01b6c8

src/insets/ChangeLog
src/insets/insettabular.C

index abb82616191881e9ce280feb86410a9bf71ade16..b8c2c8f6939761b6f385c5b76b318db8c542b73b 100644 (file)
@@ -1,3 +1,7 @@
+2003-06-02  John Levon  <levon@movementarian.org>
+
+       * insettabular.C: fix resize of column width
+
 2003-06-02  John Levon  <levon@movementarian.org>
 
        * Makefile.am:
index c3067d9c4456d4ccf532b4b0c38b365f57a35e73..ae9ff709b1bee022565918cd613060f6fa64f7e5 100644 (file)
@@ -1754,6 +1754,11 @@ void InsetTabular::tabularFeatures(BufferView * bv,
                bool const update = (tmplen != vallen);
                tabular->SetColumnPWidth(actcell, vallen);
                if (update) {
+                       // We need this otherwise we won't resize
+                       // the insettext of the active cell (if any)
+                       // until later (see InsetText::do_resize)
+                       unlockInsetInInset(bv, the_locking_inset);
+
                        int cell;
                        for (int i = 0; i < tabular->rows(); ++i) {
                                cell = tabular->GetCellNumber(i,column);
@@ -1778,6 +1783,11 @@ void InsetTabular::tabularFeatures(BufferView * bv,
                bool const update = (tmplen != vallen);
                tabular->SetMColumnPWidth(actcell, vallen);
                if (update) {
+                       // We need this otherwise we won't resize
+                       // the insettext of the active cell (if any)
+                       // until later (see InsetText::do_resize)
+                       unlockInsetInInset(bv, the_locking_inset);
+
                        for (int i = 0; i < tabular->rows(); ++i) {
                                tabular->GetCellInset(tabular->GetCellNumber(i, column))->
                                        resizeLyXText(bv);