From c3735f004fee6ba2cd1f0b4e3111a9b90378f0c1 Mon Sep 17 00:00:00 2001 From: John Levon Date: Mon, 2 Jun 2003 16:40:38 +0000 Subject: [PATCH] fix column width resize git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7086 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/insets/ChangeLog | 4 ++++ src/insets/insettabular.C | 10 ++++++++++ 2 files changed, 14 insertions(+) diff --git a/src/insets/ChangeLog b/src/insets/ChangeLog index abb8261619..b8c2c8f693 100644 --- a/src/insets/ChangeLog +++ b/src/insets/ChangeLog @@ -1,3 +1,7 @@ +2003-06-02 John Levon + + * insettabular.C: fix resize of column width + 2003-06-02 John Levon * Makefile.am: diff --git a/src/insets/insettabular.C b/src/insets/insettabular.C index c3067d9c44..ae9ff709b1 100644 --- a/src/insets/insettabular.C +++ b/src/insets/insettabular.C @@ -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); -- 2.39.2