I make a mini adventure game for Android to learn Android programming. But my textview which contains information about the game events does not scroll. I have done it programma
Layout
/>
/>
/>
Java
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_fullscreen);
// vScroll = (ScrollView) findViewById(R.id.vScroll);
scrollable = (TextView)findViewById(R.id.textView1);
//Enabling scrolling on TextView.
scrollable.setMovementMethod(new ScrollingMovementMethod());
for(int i=0;i<100;i++)
scrollable.append("q");
// TableRow tr3=(TableRow)findViewById(R.id.tableRow3);
//View v = findViewById(R.id.view);
//ag = new AdventureGame((TableLayout)findViewById(R.id.tableLayout1), scrollable, this, 5, "Jamie", onScoreListener);
// ag.setBackground(getResources().getDrawable(R.mipmap.dungeon));
// tr3.addView(ag);
// new Adventure(scrollable, this, ag);
// v = ag;
AdventureGame ag = findViewById(R.id.view);
ag.text = findViewById(R.id.textView1);
ag = findViewById(R.id.view);
new Adventure(scrollable, this, ag);
}
And it scrolls!