I have created a sample application where I want to do scrolling, but I am not able to achieve the desired output.
I have tried the following code inside paint method >>>>>
g.translate(x,y);
and passing the value for variable 'y' in keydown and keyup event.
Can anyone help me out to do this?
Have you tried with decrementing the value of Y in keyUP and calling repaint()
method also do same with keyDown but now the value of Y will be decrementing and call repaint()
method.
Use the g.translate(x, changingYvalue);
try this.