From 776b881bb7301487f7b0bf82e005b10e4b84f9a0 Mon Sep 17 00:00:00 2001 From: jcid Date: Tue, 30 Sep 2008 16:59:01 +0200 Subject: - Added a workaround for missing lines with "View Source". --- src/dialog.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/dialog.cc') diff --git a/src/dialog.cc b/src/dialog.cc index 0adb1d1a..69781f32 100644 --- a/src/dialog.cc +++ b/src/dialog.cc @@ -133,8 +133,6 @@ void *a_Dialog_make_text_window(const char *txt, const char *title) TextDisplay *td = new TextDisplay(0,0,ww, wh-bh); td->buffer()->text(txt); - /* enable wrapping lines; text uses entire width of window */ - td->wrap_mode(true, 0); if (textfont) td->textfont(textfont); @@ -148,6 +146,11 @@ void *a_Dialog_make_text_window(const char *txt, const char *title) line_num_width = (int)(line_num_width * fltk::getwidth("0")); td->linenumber_width(line_num_width); + /* enable wrapping lines; text uses entire width of window */ + td->wrap_mode(true, false); + /* WORKAROUND: FLTK may not display all the lines without this */ + td->resize(ww+1,wh-bh); + ReturnButton *b = new ReturnButton (0, wh-bh, ww, bh, "Close"); b->callback(window_close_cb, window); -- cgit v1.2.3