[Iup-users] IUP matrix with a scrollbar
Steven Mak
tcmak at yahoo.com
Wed Dec 19 05:36:04 GMT+3 2007
Hi all,
I am writing an application using IUP matrix control. Here's how it is created:
Ihandle *_mat;
_mat = IupMatrix("myaction");
IupSetAttributes(_mat,"SCROLLBAR=YES DX=0.5 DY=0.5");
IupSetAttribute(_mat,IUP_VERTICAL,"YES");
IupSetAttribute(_mat,IUP_HORIZONTAL,"YES");
IupSetAttribute(_mat,IUP_RESIZEMATRIX,"YES");
IupSetAttribute(_mat,IUP_NUMCOL,"2");
IupSetAttribute(_mat,IUP_NUMLIN,"16");
IupSetAttribute(_mat,IUP_NUMCOL_VISIBLE,"2") ;
IupSetAttribute(_mat,IUP_NUMLIN_VISIBLE,"0") ;
IupSetAttribute(_mat,"0:0","Inflation");
IupSetAttribute(_mat,"1:0","Medicine");
IupSetAttribute(_mat,"2:0","Food");
IupSetAttribute(_mat,"3:0","Energy");
IupSetAttribute(_mat,"0:1","January 2000");
IupSetAttribute(_mat,"0:2","February 2000");
IupSetAttribute(_mat,"1:1","5.6");
IupSetAttribute(_mat,"2:1","2.2");
IupSetAttribute(_mat,"3:1","7.2");
IupSetAttribute(_mat,"4:1","7.2");
IupSetAttribute(_mat,"5:1","7.2");
IupSetAttribute(_mat,"6:1","7.2");
IupSetAttribute(_mat,"7:1","7.2");
IupSetAttribute(_mat,"8:1","7.2");
IupSetAttribute(_mat,"9:1","7.2");
IupSetAttribute(_mat,"10:1","7.2");
IupSetAttribute(_mat,"11:1","7.2");
IupSetAttribute(_mat,"12:1","7.2");
IupSetAttribute(_mat,"13:1","7.2");
IupSetAttribute(_mat,"14:1","7.2");
IupSetAttribute(_mat,"15:1","7.2");
IupSetAttribute(_mat,"1:2","4.5");
IupSetAttribute(_mat,"2:2","8.1");
IupSetAttribute(_mat,"3:2","3.4");
IupSetAttribute(_mat,"4:2","3.4");
IupSetAttribute(_mat,"5:2","3.4");
IupSetAttribute(_mat,"6:2","3.4");
IupSetAttribute(_mat,"7:2","3.4");
IupSetAttribute(_mat,"8:2","3.4");
IupSetAttribute(_mat,"9:2","3.4");
IupSetAttribute(_mat,"10:2","3.4");
IupSetAttribute(_mat,"11:2","4.4");
IupSetAttribute(_mat,"12:2","4.4");
IupSetAttribute(_mat,"13:2","4.4");
IupSetAttribute(_mat,"14:2","4.4");
IupSetAttribute(_mat,"15:2","4.4");
IupSetAttribute(_mat,"WIDTHDEF","34");
IupSetAttribute(_mat,IUP_CURSOR,"ARROW");
It compiled successfully. However, the window only show upper potion of the matrix, first 12 lines. I press down arrow key in order to show the bottom rows. There is no scoll bar indicated.
I am wondering if I can have a vertical scrollbar so as to scroll down with a mouse. In fact, you can see that I have attempted to enable scrollbar. However, it wasn't shown up.
Can I know if there is anything I am wrong here? or do you have any example code for a matrix with a scrollbar.
Thank you very much,
Steven
---------------------------------
Looking for last minute shopping deals? Find them fast with Yahoo! Search.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.luaforge.net/pipermail/iup-users/attachments/20071219/3461cfda/attachment.htm
More information about the iup-users
mailing list