1 registered members (AndrewAMD),
691
guests, and 7
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Measure String
#305890
01/18/10 07:53
01/18/10 07:53
|
Joined: Nov 2007
Posts: 1,143 United Kingdom
DJBMASTER
OP
Serious User
|
OP
Serious User
Joined: Nov 2007
Posts: 1,143
United Kingdom
|
Hi, Can we have a function that returns the size in pixels of a string, rendered using a given font. The width and height should be returned in a vector...
VECTOR* str_pixels(STRING* string, FONT* font).
Of course, if there are any current methods people know, then if you wouldn't mind sharing.
Thanks, David.
Last edited by DJBMASTER; 01/18/10 08:02.
|
|
|
Re: Measure String
[Re: DJBMASTER]
#305895
01/18/10 09:29
01/18/10 09:29
|
Joined: Oct 2007
Posts: 5,210 İstanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
|
str_width (STRING*, FONT*);
check manual, i am not sure about the height tho.
3333333333
|
|
|
Re: Measure String
[Re: GorNaKosh]
#306411
01/22/10 00:29
01/22/10 00:29
|
Joined: Nov 2007
Posts: 1,143 United Kingdom
DJBMASTER
OP
Serious User
|
OP
Serious User
Joined: Nov 2007
Posts: 1,143
United Kingdom
|
Does anyone know how I could measure the height/width of the text produced by a 'digits' definition?
Last edited by DJBMASTER; 01/22/10 00:29.
|
|
|
|