Jump to content
Sign in to follow this  
nuxil

Resize listbox problem!

Recommended Posts

Hi all..

a  question to all you gui whores tounge2.gif

i come across a issue.

i have a listbox in my dialog which i use for diffrent data. so in diffrent state of the program the listbox has diffrent size "depending on what its to show".

however when i resize the listbox to a bigger size. all the text gets screwed up. the issue seams to be related to rowhight.

setting the text size is not enought.

i been looking on the wiki for a set rowhight command. but can not find any.

are there other workaround to this issue?

the reason i ask is because. i want to avoid using 2 idc's if i can use 1 instead.

Share this post


Link to post
Share on other sites

<- GUI noob

what about

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">rows = x; // x = int

Share this post


Link to post
Share on other sites

Hi Q!

icon_rolleyes.gif  what do you mean?

i dont see how that will affect rowhight! ?

could you try to explain what you meant?

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

idc = 19006;

x = -0.062;

y = 0.12;

w = 1.142;

h = 0.67;

type = CT_LISTBOX;

style = LB_TEXTURES;

colorText[] = {1, 1, 1, 1};

colorBackground[] = {0, 0, 0, 1};

font = "bitstream";

SizeEX = 0.035;

colorSelect[] = {1, 1, 0, 1};

colorSelectBackGround[] = {0.1, 0.1, 0.1, 0.5};

RowHeight = x; <--- huh.gif

soundSelect[] = {"", 0.1, 1};

soundExpand[] = {"", 0.1, 1};

soundCollapse[] = {"", 0.1, 1};

wholeHeight = x; <--- huh.gif

onLBDblClick = "[] execvm ""\scripts\list.sqf"";";

x; <--- huh.gif

i cant find any ctrlSetRow :\  which seams i am in need of

Share this post


Link to post
Share on other sites

i was hoping i could use something like

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

RowHeight = __EVAL (if (AGLOBVAR) then {0.05} else {0.02});

this only seams to work with define AGLOBVAR = "false/true"

and only reads the value once "at mission load"

i hoped to destroyed the current idc and repopen it when AGLOBVAR was set too true would work. but nop..

Share this post


Link to post
Share on other sites

Make two listboxes with different sizes and only display the needed one. Probably the easiest workaround.

Share this post


Link to post
Share on other sites

T_D i was hoping to avoid that. but that seams to be the only working solution atm..

need to summit a wish for

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">ctrlSetRowHight And <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">ctrlSetWholeHeight

Share this post


Link to post
Share on other sites

You might want to try emptying the listbox first, before you resize it, and then putting the pre-existing lines back into it again.

Share this post


Link to post
Share on other sites

Kronzky thanks for the suggestion.. but that wount|didnt help,

so 2 idc's seams to be solution

edit. :

the use of a rowhight globalvalue defined, then reopen the dialog seams to be working

tried to make all the x,y,h,w of the idc global aswell to useing ctrlsetPosition.

just need to flash the dialog fast tounge2.gif

i have to say. This sucks. we need more power for the displaycontrols.  

alot of ctrlsetX commands are missing mad_o.gif

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×