Friday, March 28, 2014

android TextView setMovementMethod slide background


Want to achieve textview slide up and down function, and indeed did, but the result is not satisfactory, the specific is this: find textview after adding the setMovementMethod this method, sliding up and down when the background is grayed, raised his hand after another back to normal, of course, not all models have this situation, I measured the seven mobile phones, found that only moto (Me525 android2.2) with Samsung (GT-N700 android2.3) the machine will not happen case, other models (ZTE (4.0.3), htc G8 (2.3), htc G7 (4.0), Samsung galaxy nexus (4.0.4)) Who knows what causes it because there can not insert a picture, so want to see Go here right effect http://zhidao.baidu.com/question/446469920.html?quesup2
<-! Main posts under Banner (D4) -><-! Posts under the main text (D5) ->
Reply:
setCacheColorHint (0x00000000);
Reply:
Problem solving, because I forgot to set the textview textColor attribute set to white enough, thank you, 1st Floor, buddy!
Reply:
How can slide up and down the code to achieve without hair?
Reply:
reference to the third floor allanence reply:
can slide up and down the code to realize how fat without?

TextView inside: android: scrollbars = "vertical"
Code: textview.setMovementMethod (ScrollingMovementMethod.getInstance ());
Reply:
TextView layout in: android: scrollbars = "vertical"
Code: textview.setMovementMethod (ScrollingMovementMethod.getInstance ());
Reply:
Thank you, brothers
Reply:
Why did I do that afterwards. Value only after the textview. Must first look textview slide controls to display the contents of the textview, not necessarily that blank space?
Reply:
reference to the 7th floor yyjsubie reply:
why I'm doing after. Value only after the textview. Must first look textview slide controls to display the contents of the textview, not necessarily that blank space?

mText.scrollTo (0, 0);

No comments:

Post a Comment