Ok, thanks. For a solution to my problem to track the size of the dialog I am reading the size of the dialog and laid out elements to calculate the size I want to allocate to the iuplist control to keep its rastersize to fit neatly in the dialog.
On Wed, Nov 7, 2018 at 12:38 PM Antonio Scuri <antonio.sc...@gmail.com> wrote: > No, if the IupList go beyond the size of the dialog it is because its > minimum size is greater than the current size of the dialog. The EXPAND=Yes > situation is when the dialog is greater than the natural size of its > contents. > > > if iuplist is used and it is going to be dynamically populated at > runtime you are now forced to use visiblelines attribute > > This not a "now", it was always like this. visiblelines was created to > solve that. Can't change that without affecting existing applications. > > Best, > Scuri > > > Em qua, 7 de nov de 2018 às 18:20, Milind Gupta <milind.gu...@gmail.com> > escreveu: > >> >>> Even IupText will occupy the space available in the dialog if it has >>> EXPAND!=NO. >>> >>> >> Actually that is what I am saying that even when IupText expands to >> occupy the space of the resize it does not go beyond the size of the dialog >> but iuplist does. Having Expand="YES" in iuplist does not effect this >> behavior. >> >> So what I understand is that if iuplist is used and it is going to be >> dynamically populated at runtime you are now forced to use visiblelines >> attribute to prevent the list elements from being inaccessible. >> >> Milind >> >> >> >> >> >>> >>> Em qua, 7 de nov de 2018 às 17:15, Milind Gupta <milind.gu...@gmail.com> >>> escreveu: >>> >>>> Hi Antonio, >>>> This behavior seems very inconsistent and unintuitive to other >>>> controls. For example if I have a text box and if the text box is filled >>>> with large amount of text it still respects the size of the dialog. >>>> Shouldn't the natural behavior always respect the dialog size in which it >>>> is placed? >>>> >>>> Milind >>>> >>>> On Wed, Nov 7, 2018 at 9:05 AM Antonio Scuri <antonio.sc...@gmail.com> >>>> wrote: >>>> >>>>> No, there isn't. >>>>> >>>>> Best, >>>>> Scuri >>>>> >>>>> Em qua, 7 de nov de 2018 15:02, Milind Gupta <milind.gu...@gmail.com >>>>> escreveu: >>>>> >>>>>> Thanks Antonio, >>>>>> Is there a way to find our how many visible lines would >>>>>> fit in a dialog when it is resized? >>>>>> >>>>>> Milind >>>>>> >>>>>> >>>>>> On Wed, Nov 7, 2018 at 5:37 AM Antonio Scuri <antonio.sc...@gmail.com> >>>>>> wrote: >>>>>> >>>>>>> Hi Milind, >>>>>>> >>>>>>> You can control that with the VISIBLELINES and VISIBLECOLUMNS >>>>>>> attributes. >>>>>>> >>>>>>> Best, >>>>>>> Scuri >>>>>>> >>>>>>> >>>>>>> Em qua, 7 de nov de 2018 00:02, Milind Gupta <milind.gu...@gmail.com >>>>>>> escreveu: >>>>>>> >>>>>>>> Hi, >>>>>>>> I have a multiple selection list control. During the >>>>>>>> operation if I put a lot of elements in the list element the scroll >>>>>>>> bars >>>>>>>> show up. But if the dialog is resized the list control size immediately >>>>>>>> explodes to however large it needs to be to remove the scrollbars and >>>>>>>> goes >>>>>>>> beyond what the dialog shows. How can I force the list control to not >>>>>>>> resize automatically beyond the dialog boundaries? >>>>>>>> The example to show the problem is below. To replicate click the >>>>>>>> Add button and then resize the dialog. >>>>>>>> >>>>>>>> require( "iuplua" ) >>>>>>>> >>>>>>>> list = iup.list{MULTIPLE="YES",["1"]="One",["2"]="Two"} >>>>>>>> button = iup.button{title="ADD",expand="YES"} >>>>>>>> >>>>>>>> vbox = iup.vbox { >>>>>>>> iup.hbox{ >>>>>>>> list, >>>>>>>> iup.label {title="Label"}, >>>>>>>> iup.text { border="NO"; value="This is good"; >>>>>>>> bgcolor=iup.GetGlobal("DLGBGCOLOR"); readonly="YES"; visiblecolumns=30 >>>>>>>> }; >>>>>>>> gap=10 >>>>>>>> }, >>>>>>>> button >>>>>>>> } >>>>>>>> function button:action() >>>>>>>> list.removeitem = "ALL" >>>>>>>> for i = 1,40 do >>>>>>>> list[tostring(i)] = "Hello"..tostring(i) >>>>>>>> end >>>>>>>> end >>>>>>>> dlg = iup.dialog{vbox; title="Dialog",size="QUARTERxQUARTER"} >>>>>>>> dlg:show() >>>>>>>> >>>>>>>> if (iup.MainLoopLevel()==0) then >>>>>>>> iup.MainLoop() >>>>>>>> end >>>>>>>> >>>>>>>> Thanks, >>>>>>>> Milind >>>>>>>> _______________________________________________ >>>>>>>> Iup-users mailing list >>>>>>>> Iup-users@lists.sourceforge.net >>>>>>>> https://lists.sourceforge.net/lists/listinfo/iup-users >>>>>>>> >>>>>>> _______________________________________________ >>>>>>> Iup-users mailing list >>>>>>> Iup-users@lists.sourceforge.net >>>>>>> https://lists.sourceforge.net/lists/listinfo/iup-users >>>>>>> >>>>>> _______________________________________________ >>>>>> Iup-users mailing list >>>>>> Iup-users@lists.sourceforge.net >>>>>> https://lists.sourceforge.net/lists/listinfo/iup-users >>>>>> >>>>> _______________________________________________ >>>>> Iup-users mailing list >>>>> Iup-users@lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/iup-users >>>>> >>>> _______________________________________________ >>>> Iup-users mailing list >>>> Iup-users@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/iup-users >>>> >>> _______________________________________________ >>> Iup-users mailing list >>> Iup-users@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/iup-users >>> >> _______________________________________________ >> Iup-users mailing list >> Iup-users@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/iup-users >> > _______________________________________________ > Iup-users mailing list > Iup-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/iup-users >
_______________________________________________ Iup-users mailing list Iup-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/iup-users