Hi,
I would like to have a kind of filmstrip along the bottom of my window, which will show small thumbnails of all the images in a specified directory.
Does anyone know if this is possible, and if so, does anyone know if there are any examples of this anywhere?
Thank you all in advance for any help you can provide.
Somewhere (in the window Open event ?), you can put code that does:
check the contents of a given folder contents,
in a loop of some sort, you load all images,
resize them to fit the kind of filmstrip size,
then maybe within a timer, you can display sequenctially the images
and loop back to image 1.
I do not want the images to animate or anything however, I simply want the thumbnail images to be displayed side-by-side in a strip along the bottom, and be able to scroll through them by the usual scrollbar.
Been a long time since I used Xojo, so I guess I will have to search the interwebs and hope I can find some kind of example project to dissect
@Norman, unfortunately both of those 2 links just suggest which class to use, but there is still no example project to learn from.
For example, it says CGImageSource is recommended, but just being told 1 word (CGImageSource) means absolutely nothing to me?
@Axel, when I run your example project - I just get an empty white strip attached to the left of my screen? Not sure what it is supposed to do?
This is obviously way to complex for me, so I will have to forget this idea
Thank you all for trying to help - I still appreciate it.
@Norman, unfortunately both of those 2 links just suggest which class to use, but there is still no example project to learn from.
For example, it says CGImageSource is recommended, but just being told 1 word (CGImageSource) means absolutely nothing to me?
@Axel, when I run your example project - I just get an empty white strip attached to the left of my screen? Not sure what it is supposed to do?
This is obviously way to complex for me, so I will have to forget this idea
Thank you all for trying to help - I still appreciate it.[/quote]
Richard – Using Axel’s example goto Window1 --> Open event.
You have to add the correct path to your images as Axel’s example has this hard coded.
me.AcceptFileDrop("")
dim f as FolderItem = GetFolderItem("/Users/mike/Pictures", 3) // <--- CHANGE TO YOUR PATH
if f <> nil and f.Exists then
ScanFolder(f, lb)
end if
You might want to change the column widths. Or change the column count when your listbox resizes.
This way you have scrolling capabilities without having to do too much. And I am sure it’s faster than drawing every single image on a canvas.
[quote=303101:@Axel Schneider]This is how it looks in Linux.
Does it look like this in OSX?
[/quote]
I testing / built this for OS-X El Capitan as I know Richard S. uses that also. I did 0 testing on this outside of OS X It literally was about 25 minutes of coding to get Richard S. an example in the most basic form. I also didn’t care about my image types/sizing since Richard Summers is a graphic design expert and I knew he would have his own images.
Woke up this morning to a multitude of answers
Thanks everyone for all your help, especially Mike and Axel, who actually spent time making a project file for me to learn from.
Much appreciated.
P.S
I will get back to you when I find time to look at the project files, as I have lots of stuff going on at the moment.
[quote=303108:@Richard Summers]Woke up this morning to a multitude of answers
Thanks everyone for all your help, especially Mike and Axel, who actually spent time making a project file for me to learn from.
Much appreciated.
P.S
I will get back to you when I find time to look at the project files, as I have lots of stuff going on at the moment.
THANK YOU.[/quote]
No worries Richard - If you have filmstrip specific images you made/use send them to me and I will incorporate them into my sample project. It would help with context most likely.