×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Regular Contributor
    Join Date
    Mar 2003
    Posts
    59

    Wrapping text in a listbox

    I'd like to create a listbox that has 3 columns. Column 1 will be an icon, column 2 a short string and column 3 a longer string. I want the text in the third column to wrap if it is too long to display on a single line. I also need to be able to set the size and colour of the font used for each listbox item.

    Having looked at the existing listbox classes I think that I need to derive my own classes from CEikFormattedCellListBox and CFormattedCellListBoxItemDrawer but I'm unclear how to progress.

    Can anyone tell me if this is possible and if I'm thinking along the right lines?

    Thanks, Mark.

  2. #2
    Regular Contributor
    Join Date
    Mar 2003
    Posts
    52
    Mark,

    Did you have any luck with text wrapping in your listbox? I'm using a CEikColumnListBox on the P800 and am not having any luck with wrapping, it just gets truncated. I figured there was a method in the item drawer class that would help, but no luck. Any feedback would be greatly appreciated.

    Thanks,
    Dennis

  3. #3
    Registered User
    Join Date
    May 2005
    Posts
    3
    Were you able to get the text wrapped in the list box. I'm trying to do something similar.

    I'm using CEikTextListBox, but it doesn't seem to provide any facility to wrap the text.

    Any suggestions would be appreciated.

    Thanks,
    nm

  4. #4
    Regular Contributor
    Join Date
    Mar 2003
    Posts
    52
    Hi Mark,

    The trick I used was to create an instance of the CEikFormattedCellListBox which supports two rows of text along with an icon. You can see an example of its use here:

    http://www.dashfly.com/products.cfm

    If you take a look at the S60 examples Nokia has provided a good listbox tutorial with several different types. I hope this helps.

    Best Regards,
    Dennis

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •