> What do I make wrong?

I'm not sure - can you post a minimal, compileable, example that shows
the failing behaviour?

Here's a simple example that *does* work...

//
// fltk1-3-config --use-images --compile scroll-test.cxx
//
#include <FL/Fl.H>
#include <FL/Fl_JPEG_Image.H>
#include <FL/Fl_Double_Window.H>
#include <FL/Fl_Scroll.H>
#include <FL/Fl_Box.H>
//
// Show how to make a scrollable image view
//
int main(int argc, char **argv) {

  if(argc < 2) {
    puts("Filename?");
    return -1;
  }
  // load a jpeg image
  Fl_JPEG_Image picture(argv[1]);

  // Create the windows and widgets
  Fl_Double_Window win(150, 150);
  win.begin();
  Fl_Scroll scroll(10, 10, win.w() - 20, win.h() - 20);
  scroll.begin();

  Fl_Box *img_box = new Fl_Box(0, 0, picture.w(), picture.h());
  img_box->image(picture);

  scroll.end();
  win.end();
  win.resizable(scroll);
  win.show();
  return Fl::run();
}

/* End of File */ 



SELEX Galileo Ltd
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 
3EL
A company registered in England & Wales.  Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************

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

Reply via email to