| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| XmHTML-1.1.10.tgz | 2015-10-26 | 1.3 MB | |
| XmHTML-1.1.9.tgz | 2014-03-19 | 1.3 MB | |
| README | 2014-02-18 | 2.3 kB | |
| XmHTML-1.1.8.tgz | 2014-02-18 | 1.3 MB | |
| libXmHTML.so.1.1.8 | 2014-02-17 | 1.8 MB | |
| Totals: 5 Items | 5.8 MB | 7 |
XmHTML README
You need a current version of Motif to use it.
===============================
How to use it:
===============================
Please look at the examples in the "examples" directory of the source.
Here is a short outline of the code ( inspired by example_1.c ):
--------------------------------------------------------------
#include <Xm/Xm.h>
#include <XmHTML/XmHTML.h>
[...]
String content;
Widget htmlParentWidget;
[... init Motif, init the parent widget for XmHtml,
in this example: variable "htmlParentWidget" ]
/* put some html-text into the variable content */
content = "<html><body><h1>Hello World</h1><p>Example Text</p></body></html>";
html = XtVaCreateManagedWidget("html",
xmHTMLWidgetClass, htmlParentWidget,
XmNmarginWidth, 20,
XmNmarginHeight, 20,
XmNwidth, 600,
XmNheight, 500,
NULL);
XmHTMLTextSetString(html, content);
[... manage widgets, main loop, etc ... ]
--------------------------------------------------------------
===============================
How to build from source:
===============================
XmHTML build works with plain Makefiles on Linux.
You can pass the following build-variables to make:
EXTRA_INCLUDES : additional include directories ( in the form -Idir, where "dir" is the directory )
LD_FLAGS : additional linker flags
HAVE_XFT : 1 means: enable XFT support, 0 means: disable XFT support
EXTRA_CPPFLAGS : additional flags for the C-Preprocessor, such macros in the form -Dmacro=value
PLATFORM : which widget library to build it for. The following values are possible:
motif : vuild it for motif ( default )
gtk : build it for gtk ( untested. I recommend to disable XFT support when building for gtk )
These build variables are especially useful when you integrate XmHTML in the build system of a larger project.
Examples:
cd $(XMHTMLDIR); make EXTRA_INCLUDES=-I$(INSTALLBASE)/include LDFLAGS=-L$(INSTALLBASE)/lib HAVE_XFT=1
cd XmHTML-1.1.8 ; make EXTRA_INCLUDES=../install/include LDFLAGS=-L../install/lib HAVE_XFT=1
cd XmHTML-1.1.8 ; make EXTRA_INCLUDES=../install/include LDFLAGS=-L../install/lib HAVE_XFT=1 HAVE_XFT=0 PLATFORM=gtk
cd XmHTML-1.1.8 ; make EXTRA_INCLUDES=../install/include LDFLAGS=-L../install/lib HAVE_XFT=1 EXTRA_CPPFLAGS=-DDEBUG