Adding form element to output

Poppler takes care of almost everything, I simply added the form tags at the end of every page.
The integers are ID's, used as CSS classes, not the values (e.g. of
height). You need to install the values and use the class IDs.

On Sat, Nov 15, 2014 at 1:08 AM, Simon Chenard <notifications@github.com>
wrote:

> In src/HTMLRenderer/form.cc:
>
> > +
> > +        w->getRect(&x1, &y1, &x2, &y2);
> > +        x1 = x1 * param.zoom;
> > +        x2 = x2 * param.zoom;
> > +        y1 = y1 * param.zoom;
> > +        y2 = y2 * param.zoom;
> > +
> > +        width = x2 - x1;
> > +        height = y2 - y1;
> > +
> > +        if(w->getType() == formText)
> > +        {
> > +            font_size = height / 2;
> > +
> > +            out << "<input id=\"text-" << std::to_string(pageNum) << "-"
> > +                << std::to_string(i) << "\" type=\"text\" value=\"\""
>
> I went ahead and cleaned it up as you suggested. However I had a question
> regarding the conversion process, from double or int to string. How come
> int are transferred in hexadecimal string of number, and not the case for
> double? Also in your example, wid and hid are of the long long type : I
> tried to use the same type, but in my case they are converted to
> hexadecimal number, which is obviously not going to work... Any idea why
> that is?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/coolwanglu/pdf2htmlEX/pull/413/files#r20371620>.
>