CaptchaImageView
CaptchaImageView copied to clipboard
Text size problem on High res devices and tablets
Font size is too small for high res devices like xxxhdpi and tables
any solution of font size?
Font size is too small for high res devices like xxxhdpi and tables in function: private static String drawRandomText set the textSizeRange arry variable as follows int[] textSizeRange = {100, 120, 140, 150};
Hello, How can I increase text size?
I used scaleX and scaleY to zoom the text, it worked fine.
<test.jinesh.captchaimageviewlib.CaptchaImageView
android:id="@+id/image"
android:layout_width="wrap_content"
android:layout_height="@dimen/_30sdp"
android:scaleX="2"
android:scaleY="2"
/>
Setting hard code value for scaleX and scaleY will not work for all resolutions if we set it to 2, then the image will be over sized for low res devices, a better solution is to add dimen files for each resolution and define dimen values like 1, 1.5, 2 etc for each density, and use that dimen value for scaleX and scaleY.