Version: 1.5rc1 (using KDE KDE 3.5.1) Steps to reproduce: 1. Select a range of rows by left-dragging across a range of row numbers in the left-hand row selector. 2. Right-click on selected row numbers in the row selector. 3. Select "Resize row..." from the context menu. 4. Hit the "Defaults" button. The default height will be the total height of all the cells. This would be fine, if the resize operation applied to the entire selected range, but the new size applies to each cell individually. The behavior of the default button should be consistent with the resize behavior. The same bug applies to selected columns.
SVN commit 530822 by nikolaus: operation 'Resize Column...', 'Resize Row...' Fix the default width/height in the 'Resize Column/Row' dialogs. Bug: 125751 M +10 -2 branches/koffice/1.5/koffice/kspread/dialogs/kspread_dlg_resize2.cc M +10 -2 trunk/koffice/kspread/dialogs/kspread_dlg_resize2.cc --- branches/koffice/1.5/koffice/kspread/dialogs/kspread_dlg_resize2.cc #530821:530822 @@ -106,7 +106,11 @@ void ResizeRow::slotDefault() { - m_pHeight->setValue( POINT_TO_MM( heightOfRow ) ); + Sheet* sheet = m_pView->activeSheet(); + if (!sheet) + return; + double points = sheet->rowFormat(0)->dblHeight(); + m_pHeight->setValue(KoUnit::toUserValue(points, m_pView->doc()->unit())); } ResizeColumn::ResizeColumn( View* parent, const char* name ) @@ -168,7 +172,11 @@ void ResizeColumn::slotDefault() { - m_pWidth->setValue( POINT_TO_MM(colWidth ) ); + Sheet* sheet = m_pView->activeSheet(); + if (!sheet) + return; + double points = sheet->columnFormat(0)->dblWidth(); + m_pWidth->setValue(KoUnit::toUserValue(points, m_pView->doc()->unit())); } --- trunk/koffice/kspread/dialogs/kspread_dlg_resize2.cc #530821:530822 @@ -111,7 +111,11 @@ void ResizeRow::slotDefault() { - m_pHeight->setValue( POINT_TO_MM( heightOfRow ) ); + Sheet* sheet = m_pView->activeSheet(); + if (!sheet) + return; + double points = sheet->rowFormat(0)->dblHeight(); + m_pHeight->setValue(KoUnit::toUserValue(points, m_pView->doc()->unit())); } ResizeColumn::ResizeColumn( View* parent, const char* name ) @@ -175,7 +179,11 @@ void ResizeColumn::slotDefault() { - m_pWidth->setValue( POINT_TO_MM(colWidth ) ); + Sheet* sheet = m_pView->activeSheet(); + if (!sheet) + return; + double points = sheet->columnFormat(0)->dblWidth(); + m_pWidth->setValue(KoUnit::toUserValue(points, m_pView->doc()->unit())); }
You need to log in before you can comment on or make changes to this bug.