PDA

View Full Version : QGridBox too many items?



georgie
10th May 2006, 09:47
I am trying to get an array of 10x10 buttons for which the icon has been set to be a small circle (i understand that is pretty average as far as usability and cluttering the screen, but it is for a very specific purpose and we haven't been able to think of any other way of presenting the information) --- I am probably looking to make them about the size and shape and layout as the smilies which are to the right of the message box when you are writing a new post except in approximately the size of the message box itself....anyhoo....so when i make a grid box, all the buttons are now about 1mm*6mm, even though there is plenty of room all around them in every direction :(

any ideas....

wysota
10th May 2006, 11:39
Maybe you should use QTableView instead?

georgie
11th May 2006, 00:49
cool thanks...
but there is still a lot of white space around the items.....how can i force the buttons to take up more of the cell, or more correctly i guess, make sure the cells stick to the size of their contents?
I've tried using resizeRowToContents, but this resizes the row to the correct size, but then still pads with whitespace so now the button is barely visible in the middle of the cell....
same thing happens with setRowHeight....

also, i'd rather not have the grid lines there.....

wysota
11th May 2006, 02:05
also, i'd rather not have the grid lines there.....

QTableView::showGrid(false)

I won't answer rest of the questions at this hour :)

georgie
11th May 2006, 02:15
haha

I won't answer rest of the questions at this hour
what u talkin about? it's 11.13 am tomorrow here in australia :P....

wysota
11th May 2006, 10:24
haha

what u talkin about? it's 11.13 am tomorrow here in australia :P....

So buy me a ticket to Australia and then I'll answer your questions at 11.13 :)

About your question, could you provide a screenshot of the current situation?

georgie
11th May 2006, 11:22
i fixed it just then...thanks anyway....i ended up drawing them straight into a QFrame instead of a layout, because of the fact that i wanted to also offset some rows (i made another thread about that though...)....that way I can be a lot more specific about exactly the position I want....also i can now have different numbers of elements which is also a good thing...