Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Printing with specific font-type and font-size

Reply
Thread Tools

Printing with specific font-type and font-size

 
 
wial
Guest
Posts: n/a
 
      11-27-2008
Hi

I am relatively new to Java, and need to create an applet that will
print a document with a specific font-type and font-size.

I succeeded in printing a document, but I don't know how to correctly
specify the font-type and font-size. I searched on the Internet, but
there are many different ways explained and they all seem a bit
cumbersome to me (last time I did printing was with the Visual Basic
Printer object, which is really straightforward).
The font-type and font-size would be valid for the whole document, I
do not need to change them along the way.

Would someone be able to provide me with some code that I can work
with, or at least point me in the right direction?

Thank you
Willem Alberda
 
Reply With Quote
 
 
 
 
Knute Johnson
Guest
Posts: n/a
 
      11-27-2008
wial wrote:
> Hi
>
> I am relatively new to Java, and need to create an applet that will
> print a document with a specific font-type and font-size.
>
> I succeeded in printing a document, but I don't know how to correctly
> specify the font-type and font-size. I searched on the Internet, but
> there are many different ways explained and they all seem a bit
> cumbersome to me (last time I did printing was with the Visual Basic
> Printer object, which is really straightforward).
> The font-type and font-size would be valid for the whole document, I
> do not need to change them along the way.
>
> Would someone be able to provide me with some code that I can work
> with, or at least point me in the right direction?
>
> Thank you
> Willem Alberda


Printing is exactly like drawing. Just set the font (and its size) with
Graphics.setFont().

--

Knute Johnson
email s/nospam/knute2008/

--
Posted via NewsDemon.com - Premium Uncensored Newsgroup Service
------->>>>>>http://www.NewsDemon.com<<<<<<------
Unlimited Access, Anonymous Accounts, Uncensored Broadband Access
 
Reply With Quote
 
 
 
 
wial
Guest
Posts: n/a
 
      11-27-2008
On Nov 27, 5:49*pm, Knute Johnson <(E-Mail Removed)>
wrote:
> wial wrote:
> > Hi

>
> > I am relatively new to Java, and need to create an applet that will
> > print a document with a specific font-type and font-size.

>
> > I succeeded in printing a document, but I don't know how to correctly
> > specify the font-type and font-size. I searched on the Internet, but
> > there are many different ways explained and they all seem a bit
> > cumbersome to me (last time I did printing was with the Visual Basic
> > Printer object, which is really straightforward).
> > The font-type and font-size would be valid for the whole document, I
> > do not need to change them along the way.

>
> > Would someone be able to provide me with some code that I can work
> > with, or at least point me in the right direction?

>
> > Thank you
> > Willem Alberda

>
> Printing is exactly like drawing. *Just set the font (and its size) with
> Graphics.setFont().
>
> --
>
> Knute Johnson
> email s/nospam/knute2008/
>
> --
> Posted via NewsDemon.com - Premium Uncensored Newsgroup Service
> * * * * * * *------->>>>>>http://www.NewsDemon.com<<<<<<------
> Unlimited Access, Anonymous Accounts, Uncensored Broadband Access- Hide quoted text -
>
> - Show quoted text -


Thank you.

Willem
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
brochure printing,online yearbook,printing,books printing,publishing elie Computer Support 2 11-27-2010 12:12 PM
brochure printing,online yearbook,printing,books printing,publishing elie Computer Support 0 08-21-2007 05:52 AM
brochure printing,online yearbook,printing,books printing,publishing elie Computer Support 0 08-21-2007 05:50 AM
brochure printing,online yearbook,printing,books printing,publishing elie Computer Support 0 08-21-2007 05:28 AM
brochure printing,online yearbook,printing,books printing,publishing elie Computer Support 0 08-18-2007 10:11 AM



Advertisments