mvnForum Homepage

Print at Apr 18, 2014 4:13:06 AM View all posts in this thread on one page
Posted by slaveofone at Jun 27, 2006 1:45:43 PM
Support 4 Graphics (Images)?
That's the question.

Can Sword and Bibletime and Gnomesword work with images/graphics?

I am working on coding Bullinger's Companion Bible and making it into a module. There are several photos, charts, timelines, and other types of graphics in it that I want to reproduce in the electronic version. Is that possible?

Posted by Osk at Aug 2, 2006 5:49:06 PM
Re: Support 4 Graphics (Images)?
Sword supports graphics. I'm not sure whether all of the frontends do, but the library and Windows frontends definitely do.

Ask on sword-devel for details of encoding.

Posted by karl at Sep 12, 2006 10:47:26 AM
Re: Support 4 Graphics (Images)?
Can Sword and Bibletime and Gnomesword work with images/graphics?


This came up on the sword-devel list a couple weeks ago. OSIS and ThML modules can both include images; in ThML (which I still generate for my modules, bad boy that I am), the syntax is "<img src="/images/xyz.jpg"/> and GnomeSword, for one, displays such images just fine. The file location is anchored to the directory where the rest of the module's files live, i.e., "images" must be a subdir there. I've built myself a "maps" module, as a "dictionary," and I open that module in a separate window. Works great. But not all the frontends do images yet -- WinSword just displays the literal text content, and I believe BibleTime displays some placeholder image in place of the intended image.

So the underlying library is happy with images. The rest of the frontends need to catch up.
----------------------------------------
Project Admin, Xiphos

Posted by JohanMarais at Jan 6, 2011 12:20:11 AM
Re: Support 4 Graphics (Images)?
I am trying to insert an image into a ThML (dictionary) module, but receive an error message, saying something about the size of the image and also that I am not using "ImageMagick".
I also copied the example from the OSIS manual into an OSIS bible module and I received axactly the same error message.

I am using Xiphos 3.1.3 under Windoews XP.

Is there somewhere instructions and examples of how to proceed please?

Thank you,

Johan

Posted by karl at Jan 6, 2011 2:35:30 PM
Re: Support 4 Graphics (Images)?
I am trying to insert an image into a ThML (dictionary) module, but receive an error message, saying something about the size of the image and also that I am not using "ImageMagick".
I am using Xiphos 3.1.3 under Windoews XP.

First, upgrade to 3.1.4, available via http://xiphos.org/, just on general principles.

Second, the error message is regrettably out of date. We no longer use ImageMagick internally to determine image size. The size is determined in order to resize (scale) the image within the pane where the image will be displayed.

If you are consistently getting this sort of problem, then you probably do not have the image placed correctly within the directory hierarchy which makes up your module content. By convention (and only that), one typically creates a subdirectory "images" in which such files go. Then the reference within your module's content should be <img src="/images/YourImageFile.png"> or somesuch similar thing.

The other possibility is that the image's type is not known, though this is unlikely. Xiphos (using GTK) understands at least gif, jpg, bmp, and png.
----------------------------------------
Project Admin, Xiphos

Posted by JohanMarais at Jan 7, 2011 12:10:54 AM
Re: Support 4 Graphics (Images)?
Thank you Karl.

My directory sctructure is as follows:
C:\Program Files\Crosswire\The SWORD Project\modules\lexdict\rawld\ts2009en where ts2009en is where the dictionary files (.idx and .dat and the image file) reside.

Is your suggestion to create a directory underneath \ts2009en, i.e. C:\Program Files\Crosswire\The SWORD Project\modules\lexdict\rawld\ts2009en\images and then use the example as per your post?

The image is a 35Kb .jpg file which I am testing with to get the syntax right before venturing into the correct images and maps.

Please be patient with me as I am an end-user.

Johan

Posted by JohanMarais at Jan 7, 2011 3:22:53 AM
Re: Support 4 Graphics (Images)?
Karl,

I think I got it sorted, I created a sub-directory under ts2009en and put my images there.

Is the idea to show a small picture in the Dictionary (where I am testing currently) and when clicking on the image, to display a full-screen image in Windows Picture and Fax Viewer?

It shows the .png, .gif and .jpg images correctly, ranging in size between 35Kb to 764Kb.

In His Name.

Johan