~ubuntu-branches/ubuntu/breezy/koffice/breezy-security

« back to all changes in this revision

Viewing changes to karbon/tools/vsinustool.cc

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2005-10-11 14:49:50 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20051011144950-lwpngbifzp8nk0ds
Tags: 1:1.4.1-0ubuntu7
* SECURITY UPDATE: fix heap based buffer overflow in the RTF importer of KWord
* Opening specially crafted RTF files in KWord can cause
  execution of abitrary code.
* Add kubuntu_01_rtfimport_heap_overflow.diff
* References:
  CAN-2005-2971
  CESA-2005-005
  http://www.koffice.org/security/advisory-20051011-1.txt

Show diffs side-by-side

added added

removed removed

Lines of Context:
38
38
        QGroupBox *group = new QGroupBox( 2, Qt::Horizontal, i18n( "Properties" ), this );
39
39
 
40
40
        // add width/height-input:
41
 
        m_widthLabel = new QLabel( i18n( "Width:" ), group );
42
 
        m_width = new KoUnitDoubleSpinBox( group, 0.0, 1000.0, 0.5, 100.0, KoUnit::U_MM );
43
 
        m_heightLabel = new QLabel( i18n( "Height:" ), group );
44
 
        m_height = new KoUnitDoubleSpinBox( group, 0.0, 1000.0, 0.5, 100.0, KoUnit::U_MM );
 
41
        new QLabel( i18n( "Width:" ), group );
 
42
        m_width = new KDoubleSpinBox( 0.0, 1000.0, 0.5, 10.0, 2, group );
 
43
        //m_width = new KoBuggyUnitDoubleSpinBox( group, 0.0, 1000.0, 0.5, 100.0, KoUnit::U_MM );
 
44
        new QLabel( i18n( "Height:" ), group );
 
45
        m_height = new KDoubleSpinBox( 0.0, 1000.0, 0.5, 10.0, 2, group );
 
46
        //m_height = new KoBuggyUnitDoubleSpinBox( group, 0.0, 1000.0, 0.5, 100.0, KoUnit::U_MM );
45
47
 
46
48
        refreshUnit();
47
49
 
95
97
void
96
98
VSinusTool::VSinusOptionsWidget::refreshUnit ()
97
99
{
98
 
        m_width->setUnit( m_part->unit() );
99
 
        m_height->setUnit( m_part->unit() );
 
100
        m_width->setSuffix( KoUnit::unitName( m_part->unit() ) );
 
101
        m_height->setSuffix( KoUnit::unitName( m_part->unit() ) );
100
102
}
101
103
 
102
104
VSinusTool::VSinusTool( KarbonPart *part )
127
129
                        new VSinus(
128
130
                                0L,
129
131
                                m_p,
130
 
                                KoUnit::ptFromUnit( m_optionsWidget->width(), view()->part()->unit() ),
131
 
                                KoUnit::ptFromUnit( m_optionsWidget->height(), view()->part()->unit() ),
 
132
                                KoUnit::fromUserValue( m_optionsWidget->width(), view()->part()->unit() ),
 
133
                                KoUnit::fromUserValue( m_optionsWidget->height(), view()->part()->unit() ),
132
134
                                m_optionsWidget->periods() );
133
135
        else
134
136
                return