Display a photo in a ListBox???

Hello,

Anybody know if it is possible to display an image (photograph) as a background in a listbox? I tried loading an image to an image component and placing the component over the Listbox. The Image was set to Transparent:=True but this did nothing. I would like to be able to use a photograph as a Listbox background but have it dimmed so it doesn't interfere with viewing the items in the Listbox. If anybody has any ideas I would greatly appreciate it.

Thanks,

Guy

Comments

  • : Hello,
    :
    : Anybody know if it is possible to display an image (photograph) as a background in a listbox? I tried loading an image to an image component and placing the component over the Listbox. The Image was set to Transparent:=True but this did nothing. I would like to be able to use a photograph as a Listbox background but have it dimmed so it doesn't interfere with viewing the items in the Listbox. If anybody has any ideas I would greatly appreciate it.
    :
    : Thanks,
    :
    : Guy
    :
    :
    Try painting the image on the TListBox.Canvas. You might need to assign an event to the OnDrawItem() for it to work correctly.
  • : : Hello,
    : :
    : : Anybody know if it is possible to display an image (photograph) as a background in a listbox? I tried loading an image to an image component and placing the component over the Listbox. The Image was set to Transparent:=True but this did nothing. I would like to be able to use a photograph as a Listbox background but have it dimmed so it doesn't interfere with viewing the items in the Listbox. If anybody has any ideas I would greatly appreciate it.
    : :
    : : Thanks,
    : :
    : : Guy
    : :
    : :
    : Try painting the image on the TListBox.Canvas. You might need to assign an event to the OnDrawItem() for it to work correctly.
    :

    Well I tried this and it sort of worked. Some problems were:
    1) No photo if the list box is empty. The photo will only show on lines in the list box. If the list box is 1/2 full only 1/2 picture shows.
    2) Don't know how to make the photo dim - it is bright and almost obscures the items in the list box.
    Any Suggestions out there?
    Thanks in advance if you have any ideas.
    Guy
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories