Drawing line less than one pixel thick requires anti-aliasing in Android 4.2
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I'm trying to draw a very thin line (less than one pixel thick) in android. I'm using Paint blackThin = new Paint (); blackThin . setStrokeWidth ( 0.1f ); blackThin . setColor ( Color . BLACK ); to initialize the paint object. This works fine in Android 2.2, but when I try it in 4.2 (also 4.1, I think - I tested that one briefly - I haven't tested any other versions other that 2.2, 4.1.2 and 4.2) the lines won't show up when I draw them. To make them show up in 4.2, it seems like I have to set the anti-aliasing flag to be true. (I