Code example for ScrollView

Methods: smoothScrollTo

0
		final Handler outputHandler = new Handler() {
			@Override 
			public void handleMessage(Message msg) {
				super.handleMessage(msg);
				output.append((CharSequence) msg.obj);
				outputScroller.smoothScrollTo(0, output.getBottom());
			} 
		}; 
		 
		os = new ByteArrayOutputStream(100000) {
			@Override 
			public void write(byte[] buffer) throws java.io.IOException {
				Message msg = outputHandler.obtainMessage();
				char[] charBuffer = (new String(buffer)).toCharArray();
				msg.obj = String.valueOf(charBuffer);
				outputHandler.sendMessage(msg);
				super.write(buffer);
			}; 
 
			@Override 
			public synchronized void write(byte[] buffer, int offset, int len) {