Hello,

Could somebody help me with the following problem please?

I have a Fl_Text_Display widget, where I sometimes insert text, that is wider 
and higher than widget width and height. The scroll bars appear automatically, 
but the scrolling doesn't work properly. During scrolling empty lines appear in 
my text, and successively I'm not able to get to the last line of my text.
I use code as follows:

m_errorTextBox = new Fl_Text_Display(x, yt, w, h );
        if( m_errorTextBox )
        {
                m_errorTextBuffer = new Fl_Text_Buffer();
                m_errorTextBox->buffer( m_errorTextBuffer );
                m_errorTextBox->box( FL_DOWN_BOX );
                m_errorTextBox->insert(  msg.getErrorText().c_str() );
                m_errorTextBox->textfont( ERROR_FONT_FAMILY );
                m_errorTextBox->textsize( ERROR_FONT_SIZE );

                m_errorTextBox->color(FL_WHITE);
                float fontWidth = fl_width('m');
                m_errorTextBox->wrap_mode( 1, 
(int)((float)m_errorTextBox->w()/fontWidth) );
        }

Thank you in advance,

Kveto
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to