adding a scrollbar to a choices list?
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
- milk
- Newbie
- Posts: 3
- Joined: Thu Jan 25, 2018 9:29 am
- Projects: tales of link preservation project
- Contact:
adding a scrollbar to a choices list?
hi! i'm new to ren'py, i just starting messing around with it a few days ago, and have found myself in a predicament.
is it possible to add a scrollbar to a list of choices that is too large to display on the screen at once?
(i know this sounds insane, but it's a lot simpler than what it implies i think.)
i've tried changing the size of the fonts, but it just makes it look clunky and hard to read.
i tried a few google searches but nothing came up for quite this problem.
i hope i'm being clear, i'm not used to speaking in like. technical language, especially not in regards to this. ;w;
is it possible to add a scrollbar to a list of choices that is too large to display on the screen at once?
(i know this sounds insane, but it's a lot simpler than what it implies i think.)
i've tried changing the size of the fonts, but it just makes it look clunky and hard to read.
i tried a few google searches but nothing came up for quite this problem.
i hope i'm being clear, i'm not used to speaking in like. technical language, especially not in regards to this. ;w;
breakin hearts and crashin programs
- Remix
- Eileen-Class Veteran
- Posts: 1311
- Joined: Tue May 30, 2017 6:10 am
- Completed: None... yet (as I'm still looking for an artist)
- Projects: An un-named anime based trainer game
- Contact:
Re: adding a scrollbar to a choices list?
You would want to amend the screen choice (in screens.rpy) to wrap the buttons in a scrollable area such as a viewport. There are examples of viewports in the same file, tutorial or documentation
Mad Scientist Todo List:
- Finish Improved Event Handler
- Implement DragonBones animation as a Creator Defined Container
- Develop Cartoon Speech Bubble dialogue
- Finish Bitmask collision and rebound vector system
- Develop time based building mechanic
- Others
- *Find a superb artist and actually write a game*
- milk
- Newbie
- Posts: 3
- Joined: Thu Jan 25, 2018 9:29 am
- Projects: tales of link preservation project
- Contact:
Re: adding a scrollbar to a choices list?
thanks for responding! ^o^
good to know it should be able to be done..!
i've now certainly managed to add... uh, something, into the screen.

the menu itself isn't in it, though, and the larger one doesn't scroll or anything?
there is definitely something i'm missing here... i looked in the tutorial but i didn't learn anything useful i don't think.
this is what i have now....
i'm really sorry if i'm missing something obvious >_<;
good to know it should be able to be done..!
i've now certainly managed to add... uh, something, into the screen.

the menu itself isn't in it, though, and the larger one doesn't scroll or anything?
there is definitely something i'm missing here... i looked in the tutorial but i didn't learn anything useful i don't think.

this is what i have now....
Code: Select all
screen choice(items):
style_prefix "choice"
frame:
viewport:
scrollbars "vertical"
xmaximum 400
ymaximum 400
mousewheel True
has vbox
vbox:
for i in items:
textbutton i.caption action i.action
breakin hearts and crashin programs
- Empish
- Veteran
- Posts: 221
- Joined: Thu Jan 14, 2016 9:52 pm
- Projects: Efemural Hearts, It Ends With Graduation
- itch: empish
- Contact:
Re: adding a scrollbar to a choices list?
You want your vbox with the items to be inside the viewport. So it and all its items need to be indented in a couple times.
- milk
- Newbie
- Posts: 3
- Joined: Thu Jan 25, 2018 9:29 am
- Projects: tales of link preservation project
- Contact:
Re: adding a scrollbar to a choices list?
oh wow oh my gosh it worked, thank you so much!
i need to tweak the way it looks, certainly, but this is wonderful, i'm so happy! thanks you so much! ;w;♥
i need to tweak the way it looks, certainly, but this is wonderful, i'm so happy! thanks you so much! ;w;♥
breakin hearts and crashin programs
Who is online
Users browsing this forum: Andredron