In gcjwebplugin.cc there's a code block that could be suitable for doing the transformation from 100% --> real value.
It seems to have all the required information present.
gcjwebplugin.cc
// The last plugin window width sent to us by the browser.
guint32 window_width;
// The last plugin window height sent to us by the browser.
guint32 window_height;
// Build up the applet tag string that we'll send to the applet
// viewer.
static gchar*
plugin_create_applet_tag (int16 argc, char* argn[], char* argv[])
{
In gcjwebplugin.cc there's a code block that could be suitable for doing the transformation from 100% --> real value.
It seems to have all the required information present.
gcjwebplugin.cc
// The last plugin window width sent to us by the browser.
guint32 window_width;
// The last plugin window height sent to us by the browser.
guint32 window_height;
// Build up the applet tag string that we'll send to the applet create_ applet_ tag (int16 argc, char* argn[], char* argv[])
// viewer.
static gchar*
plugin_
{
...
else if (!g_ascii_ strcasecmp (argn[i], "width"))
applet_ tag = g_strconcat (applet_tag, width, NULL);
{
gchar* width = g_strdup_printf ("WIDTH=\"%s\" ", argv[i]);
g_free (width);
width = NULL;
}
Just check if argv[i] ends in % and do little calculation and voila.
And same thing for the height.