W3C home > Mailing lists > Public > www-lib@w3.org > April to June 1996

Re: Inconsistent libwww (bug?)

From: Kevin Kenny <kennykb@cobweb.crd.ge.com>
Date: Mon, 15 Apr 96 17:04:14 -0500
Message-Id: <9604151704.AA09676@cobweb.crd.ge.com>
To: "Mihai T. LAZARESCU" <mihai@ccmserv.polito.it>
Cc: www-lib@w3.org
"Mihai T. LAZARESCU" <mihai@ccmserv.polito.it> utters:
>I tried to add the html-to-plain conversion facility to w3c (ComLine)
>but the linker complains:
>ld: Undefined symbol
>   _HText_beginAnchor
> [... et cetera...]

The missinbg functions are callbacks from the HTML presenter.
The way that the library is structured also makes it impossible to
make a shared library out of it.

Henrik, would it be possible to replace these with pointers-to-functions
that the user can fill in at initialization time?  In my private version,
I've added the following HTextCallback.c module.  It would also cure
LAZARESCU's problem, since the missing routines are not called at run time
in the scenario that the message describes.

--- HTextCallback.c ---
#include "WWWUtil.h"
#include "HText.h"

#define PROXY(type,name,args,shortargs) \
type (*APP_ ## name) args; \
type name args { return APP_ ## name shortargs; }

#define PROXYVOID(name,args,shortargs) \
void (*APP_ ## name) args; \
void name args { APP_ ## name shortargs; }

PROXY(HText *,  HText_new2,      (HTRequest *            request,
				  HTParentAnchor *       anchor,
				  HTStream *             output_stream),
      (request, anchor, output_stream))

PROXYVOID(HText_beginAppend, (HText * text),

PROXYVOID(HText_endAppend, (HText * text),

PROXYVOID(HText_setStyle, (HText * text, HTStyle * style),
	  (text, style))

PROXYVOID(HText_appendCharacter, (HText * text, char ch),
	  (text, ch))

PROXYVOID(HText_appendText, (HText * text, CONST char * str),
	  (text, str))

PROXYVOID(HText_appendParagraph, (HText * text),

PROXYVOID(HText_beginAnchor, (HText * text, HTChildAnchor * anc),
	  (text, anc))

PROXYVOID(HText_endAnchor, (HText * text),

PROXYVOID(HText_appendImage, (
        HText *         text,
        HTChildAnchor * anc,
        CONST char *    alternative_text,
        CONST char *    alignment,
        BOOL            isMap),
	  (text, anc, alternative_text, alignment, isMap))

HTStyleSheet * styleSheet;
--- end of HTextCallback.c ---
73 de ke9tv/2, Kevin KENNY   GE Corporate Research & Development
kennykb@crd.ge.com           P. O. Box 8, Room KWC273
                             Schenectady, New York 12301-0008 USA
Received on Monday, 15 April 1996 13:12:12 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 23 April 2007 18:18:26 GMT