[jsword-devel] Re: Font as applet resource?

Patrick Durusau jsword-devel@crosswire.org
Mon, 08 Mar 2004 09:48:51 -0500


Troy,

Thanks for the cross-posting of your reply.

Did find an answer to the immediate question (see below) but will need a 
lot of help getting anything useful out the door. Can provide more 
details if anyone is interested.

Oh, on the font question, turns out there is a method in the API for it:

in Font:

public static Font createFont(int fontFormat,
InputStream fontStream)
throws FontFormatException,
IOExceptionReturns

which loads TrueType fonts

Will probably need to use Swing in the Applet to get half-way decent 
rendering on the Hebrew.

Hope everyone is having a great day!

Patrick

Troy A. Griffitts wrote:
> Patrick,
>     I haven't done applet stuff in a really long time.  I'll see if our 
> jsword-devel group has anyone willing to look into this one.
> 
> jsword-devel,
>     Hey guys.  Is there anyone that might be able to get our jsword-old 
> ModEdit application working as an applet.  I really don't know the steps 
> involved these days to get it to work in the security model of a 
> browser.  Here are the steps to get, compile, and run the mentioned app:
> 
> export CVSROOT=:pserver:anonymous@cvs.crosswire.org:/cvs/core
> cvs login
> password: anonymous
> cvs co jsword-old
> cd jsword-old
> ./configure
> make
> cd apps/ModEdit
> make
> java -jar ModEdit.jar
> 
> After getting it working, as-is,  I think Patrick would like the font 
> included in the .jar file for the applet, and accessed from there 
> instead of the URL loading that you will notice when you try the 
> application.
> 
> After getting THAT working, maybe someone might be able to provide 
> another of our custom input methods-- in addition to the 2 that are 
> included in the current app.  That works with the mapping mentioned in 
> the quoted email below.  It may be close to one that we already have and 
> only a few keystrokes might need to be added;  I haven't looked at the 
> mapping yet.
> 
> Here are the files metioned in the email below:
> 
> http://crosswire.org/sword/ALPHAcckswwlkrfre22034820285912/alpha/SBL_Hbrw.ttf 
> 
> http://crosswire.org/sword/ALPHAcckswwlkrfre22034820285912/alpha/SBLHebrew-Manual.pdf 
> 
> 
>     Thanks for considering this project,
>         -Troy.
> 
> 
> 
> Patrick Durusau wrote:
> 
>> Troy,
>>
>> I have attached the lastest Unicode/OpenType version of the SBL Hebrew 
>> font. Would it be possible for you to compile it into a Java resource 
>> that I can call from an applet? Like what you did for Kirk and myself.
>>
>> I am trying my hand at writing some demo applets for the Hebrew 
>> Grammar and the display just sucks with the default font. Have not 
>> done anything but some display tests but thought I should solve the 
>> problems as I came across them.
>>
>> I have also attached the manual which has the keyboard map, which I 
>> will need for some of the later applets but right now I am just 
>> calling the characters with \u**** strings.
>>
>> The first one I was going to do was a basic flash card, just compiling 
>> all the stuff in until they settle on the interface design, then will 
>> move the data to outside files, probably passed as parameters to the 
>> applet from a page where you select what vocabulary you want to drill 
>> on, etc.
>>
>> Thanks!
>>
>> Hope you are having a great day!
>>
>> Patrick
>>
> 
> 


-- 
Patrick Durusau
Director of Research and Development
Society of Biblical Literature
Patrick.Durusau@sbl-site.org
Chair, V1 - Text Processing: Office and Publishing Systems Interface
Co-Editor, ISO 13250, Topic Maps -- Reference Model

Topic Maps: Human, not artificial, intelligence at work!