I have been looking for DIP information for the DrawText method against the ImageView. I am currently designing and debugging on the device itself.
DipToCurrent doesn't seem to apply for that device. Even IntToDIP methods do not work either. Is this device just special, or unique in the Android world? Basically, if you place something as simple as:
The problem are the x and y values in your code.
The y coordinate of the reference point is the base line of the text not the top of the text.
In your first code example you set the y reference to 10dip for a text size of 24 which is by far too low.
Try the code below:
Thank you for the replies. Then I am thoroughly confused.
I am trying to draw some text via canvas onto an ImageView at the 0,0 location, or even 5,5 on the image. It sounds like the x and y parameters are not really for the left and top position? By baseline you mean the bottom of the text?
Thank you for the explanation That is definitely a difference between other languages. Usually, X = left, and Y = top. I'm going to have to go through other methods to see if the same difference is there.