I have just got scroll view working on a 1024 x 2024 jpeg
the only problem is that the image defaults to the left and only takes up half the (landscpe) width.
I thought the problem could be rectified by changing my config settings.
no dice.
does anyone have any thoughts on this? [import]uid: 155893 topic_id: 33685 reply_id: 333685[/import]
Can you post some code showing how you create your scrollView, how you are creating the image? And your config.lua might be helpful as well. Don’t forget to use <code> and </code> tags to wrap your code!
[import]uid: 199310 topic_id: 33685 reply_id: 133946[/import]
Couple of things. I think your config.lua should either be: zoomEven or zoomStretch
Next, why are you setting the top and bottom to the same values?
local topBoundary = display.ScreenOriginY
local bottomBoundary = display.ScreenOriginY
local scrollView = scrollView.new { top=topBoundary, bottom=bottomBoundary }
finally you never position the background or the scrollView, both will default to 0,0 which is the top left corner. [import]uid: 199310 topic_id: 33685 reply_id: 134162[/import]
Can you post some code showing how you create your scrollView, how you are creating the image? And your config.lua might be helpful as well. Don’t forget to use <code> and </code> tags to wrap your code!
[import]uid: 199310 topic_id: 33685 reply_id: 133946[/import]
Couple of things. I think your config.lua should either be: zoomEven or zoomStretch
Next, why are you setting the top and bottom to the same values?
local topBoundary = display.ScreenOriginY
local bottomBoundary = display.ScreenOriginY
local scrollView = scrollView.new { top=topBoundary, bottom=bottomBoundary }
finally you never position the background or the scrollView, both will default to 0,0 which is the top left corner. [import]uid: 199310 topic_id: 33685 reply_id: 134162[/import]
Thanks for the reply there.
how do i set the scrollview and the background so it sits the way i want?
and i dont know why im setting the top and bottom to the same values because im not a coder and dont have a clue when it comes to this.
do you know what code i should be using? [import]uid: 155893 topic_id: 33685 reply_id: 134475[/import]
First, I would suggest switching to the widget.scrollView() API instead of using the version you are including since the widget.scrollView() is the supported method.
Thanks for the reply there.
how do i set the scrollview and the background so it sits the way i want?
and i dont know why im setting the top and bottom to the same values because im not a coder and dont have a clue when it comes to this.
do you know what code i should be using? [import]uid: 155893 topic_id: 33685 reply_id: 134475[/import]
First, I would suggest switching to the widget.scrollView() API instead of using the version you are including since the widget.scrollView() is the supported method.