473,320 Members | 2,012 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

TTF Kerning

Has anyone else encountered the problem of TTF files when called upon to
generate text in PHP don't seem to have their kerning values applied? Has
anyone figured out how to fix it?
Feb 11 '06 #1
4 4268
"EvilJordan" <Ev********@aol.com> wrote:

Has anyone else encountered the problem of TTF files when called upon to
generate text in PHP don't seem to have their kerning values applied? Has
anyone figured out how to fix it?


I don't understand the connection with PHP here. Are you saying, for
example, that this doesn't look right:

<html><body>
<span style="font: 14pt Comic Sans MS">Testing</span>
</body></html>

You understand that you can't use arbitrary font files in a web page,
unless the browser's system also happens to have that font installed?

If I've misunderstood your question, try it again with an example.
--
- Tim Roberts, ti**@probo.com
Providenza & Boekelheide, Inc.
Feb 11 '06 #2
On 2006-02-11, EvilJordan <Ev********@aol.com> wrote:
Has anyone else encountered the problem of TTF files when called upon to
generate text in PHP don't seem to have their kerning values applied? Has
anyone figured out how to fix it?


how are you rendering text using ttf and php?
are you, for instance, using the GTK stuff?

Bye.
Jasen
Feb 11 '06 #3
I'm using the built in functions that cooperate with the GD library
(imagettftext, imagettfbbox, etc.)

"Jasen Betts" <ja***@free.net.nz> wrote in message
news:24*****************@clunker.homenet...
On 2006-02-11, EvilJordan <Ev********@aol.com> wrote:
Has anyone else encountered the problem of TTF files when called upon to
generate text in PHP don't seem to have their kerning values applied? Has
anyone figured out how to fix it?


how are you rendering text using ttf and php?
are you, for instance, using the GTK stuff?

Bye.
Jasen

Feb 11 '06 #4
Yes, I understand arbitrary fonts can't be used on a webpage. PHP handles
this on the server, with any font you install on the server, then spits out
an image to the client's website. Look at the functions imagettftext and
imagepstext.

Here's an example: http://www.stewartspeak.com/dtr/demo/

And yes, I'm saying if you start typeing with any font in PHP using the TTF
functions, PHP GD ignores the built in Kerning. ImageMagick does not, but
doesn't have native PHP front end support, and MagickWand is a POS.

"Tim Roberts" <ti**@probo.com> wrote in message
news:3c********************************@4ax.com...
"EvilJordan" <Ev********@aol.com> wrote:

Has anyone else encountered the problem of TTF files when called upon to
generate text in PHP don't seem to have their kerning values applied? Has
anyone figured out how to fix it?


I don't understand the connection with PHP here. Are you saying, for
example, that this doesn't look right:

<html><body>
<span style="font: 14pt Comic Sans MS">Testing</span>
</body></html>

You understand that you can't use arbitrary font files in a web page,
unless the browser's system also happens to have that font installed?

If I've misunderstood your question, try it again with an example.
--
- Tim Roberts, ti**@probo.com
Providenza & Boekelheide, Inc.

Feb 11 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

133
by: Philipp Lenssen | last post by:
Why is there no standardized and well-working way for a web-page to offer the font for download/embed it, in order to be displayed on the page? No matter what you think of the preferred font of a...
3
by: cnlai | last post by:
I created a line made up of repeated groups of "1234567890" using Courier New, size 8 (Epson Photo 900). I then printed it using Microsoft Word, and Microsoft Access Report. I expected the...
5
by: Steve | last post by:
I need a way to programatically change the width of a textbox to display all the data knowing the font, font size and number of characters. Does any oone know of a reference somewhere ot a way to...
9
by: Adam | last post by:
Can someone please help!! I am trying to figure out what a font is? Assume I am working with a fixed font say Courier 10 point font Question 1: What does this mean 10 point font Question 2:...
5
by: John Wood | last post by:
For some reason whenever I use StringFormat with a trimming set to EllipsesCharacter, when it does clip the string, it seems to reduce the kerning (it squishes the letters together). Has anyone...
4
by: cashdeskmac | last post by:
I want to justify the text in a label control so that all of the text fills the label equally, but there don't seem to be any properties to set to allow this. Can anyone help?
28
by: richardlang | last post by:
Anyone out there ever come across a preprocessor macro that compares an argument value against the predefined __DATE__ macro in order to control conditional compilation based on date. Something...
2
by: staryeyes47 | last post by:
Hi, I am creating a contact page for a my website and I am having a bit of trouble. I have created the form in flash, and am using a php file to send the email to myself. The form works OK, but...
0
by: 112vijay | last post by:
Hi, I need code of leading and kerning of the text in C#. Regards, Vijay
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.