Manish Gurnaney | 19 Jul 17:25 2014
Picon

Build error while building debug binary

Hi,
  I have one query. I am trying build webkit wiith debug symbols but I am getting one error. which says :-
Error :- 
  Can't open <PATH>WebKitBuild/Debug/DerivedSources/webkitdom/WebKitDOMDeprecated.h: No such file or directory at /<PATH>/WebKitBuild/Dependencies/Root/bin/gtkdoc-mkdb line 3889

Can you please help me in this case ?

Regards,
Manish R Gurnaney
<div><div dir="ltr">
<div>Hi,</div>
<div>&nbsp; I have one query. I am trying build webkit wiith debug symbols but I am getting one error. which says :-</div>
<div>Error :-&nbsp;</div>
<div>&nbsp; Can't open &lt;PATH&gt;WebKitBuild/Debug/DerivedSources/webkitdom/WebKitDOMDeprecated.h: No such file or directory at /&lt;PATH&gt;/WebKitBuild/Dependencies/Root/bin/gtkdoc-mkdb line 3889</div>
<div><br></div>
<div>Can you please help me in this case ?</div>
<div><br></div>
<div>Regards,</div>
<div>Manish R Gurnaney</div>
</div></div>
Dev Poudel | 9 Jul 16:39 2014
Picon

STIX and MathJX

I am trying to build webkit in windows using cygwin.
When I run update-webkit I get follwoing error:

At revision 170915.
Checking Last-Modified date of WebKitAuxiliaryLibrary.zip...
Current WebKitAuxiliaryLibrary is up to date
svn 1.7.10 is known to be compatible with our servers. You are running svn, version 1.8.9 (r1591380),
which may not work properly.
Error (2): The system cannot find the file specified.

Error (2): The system cannot find the file specified.

*************************************************************
Mathematical fonts, such as STIX and MathJax, are needed to
use the MathML feature.  You do not appear to have these fonts
on your system.

You can download a suitable set of fonts from the following URL:
https://developer.mozilla.org/Mozilla/MathML_Projects/Fonts
*************************************************************
Installed tools are correct for the WebKit build.
Setting the Environment Variable 'WEBKIT_LIBRARIES' to 'C:\cygwin\home\pouddev\WebKit\WebKitLibraries\win'

Setting the Environment Variable 'MSBUILDDISABLENODEREUSE' to '1'

Setting the Environment Variable 'WEBKIT_OUTPUTDIR' to 'C:\cygwin\home\pouddev\WebKit\WebKitBuild'

Please restart your computer before attempting to build inside Visual Studio.


I do not find any way to install these libraries from cygwin setup.
If I download in zip in which folder should I keep inside webkit to make it accessible.
Where should I find these missing files.

Thanks
Dev

<div><div dir="ltr">
<div>
<div>
<div>I am trying to build webkit in windows using cygwin.<br>When I run update-webkit I get follwoing error:<br><br><span>At revision 170915.<br>Checking Last-Modified date of WebKitAuxiliaryLibrary.zip...<br>
Current WebKitAuxiliaryLibrary is up to date<br>svn 1.7.10 is known to be compatible with our servers. You are running svn, version 1.8.9 (r1591380),<br>which may not work properly.<br>Error (2): The system cannot find the file specified.<br><br>Error (2): The system cannot find the file specified.<br><br>*************************************************************<br>Mathematical fonts, such as STIX and MathJax, are needed to<br>use the MathML feature.&nbsp; You do not appear to have these fonts<br>
on your system.<br><br>You can download a suitable set of fonts from the following URL:<br><a href="https://developer.mozilla.org/Mozilla/MathML_Projects/Fonts">https://developer.mozilla.org/Mozilla/MathML_Projects/Fonts</a><br>
*************************************************************<br>Installed tools are correct for the WebKit build.<br>Setting the Environment Variable 'WEBKIT_LIBRARIES' to 'C:\cygwin\home\pouddev\WebKit\WebKitLibraries\win'<br><br>Setting the Environment Variable 'MSBUILDDISABLENODEREUSE' to '1'<br><br>Setting the Environment Variable 'WEBKIT_OUTPUTDIR' to 'C:\cygwin\home\pouddev\WebKit\WebKitBuild'<br><br>Please restart your computer before attempting to build inside Visual Studio.</span><br><br>
</div>I do not find any way to install these libraries from cygwin setup.<br>If I download in zip in which folder should I keep inside webkit to make it accessible.<br>
</div>Where should I find these missing files.<br><br>
</div>Thanks<br>Dev<br><div><div><div><div><br></div></div></div></div>
</div></div>
Wenting Liu | 7 Jul 19:51 2014
256481788 | 27 Jun 03:46 2014

The script "update-webkit" in "WebKit-r170147\Tools\Scripts" may has problem

The code in WebKit-r170147\Tools\Scripts\update-webkit at line 83-89 is below:
 
83:} elsif (isAppleWinWebKit()) {
84:    system("perl", "Tools/Scripts/update-webkit-auxiliary-libs") == 0 or die;
85:    if (isWinCairo()) {
86:        # WinCairo shares the auxiliary libs from the Apple port.
87:        system("perl", "Tools/Scripts/update-webkit-wincairo-libs") == 0 or die;
88:    }
89:}
 
and I find the function "isAppleWinWebKit()" in  WebKit-r170147\Tools\Scripts\webkitdirs.pm
 
sub isAppleWinWebKit()
{
    return (isCygwin() || isWindows()) && !isWinCairo() && !isGtk() && !isWinCE();
}
 
the problem is that isAppleWinWebKit() means !isWinCairo() ,so the WebKit-r170147\Tools\Scripts\update-webkit line:85 is allways false.
why ? is it a problem?
256481788
<div>
<div>The code in WebKit-r170147\Tools\Scripts\update-webkit at line 83-89 is 
below:</div>
<div>&nbsp;</div>
<div>
<div>83:}&nbsp;elsif&nbsp;(isAppleWinWebKit())&nbsp;{</div>
<div>84:&nbsp;&nbsp;&nbsp;&nbsp;system("perl",&nbsp;"Tools/Scripts/update-webkit-auxiliary-libs")&nbsp;==&nbsp;0&nbsp;or&nbsp;die;</div>
<div>85:&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;(isWinCairo())&nbsp;{</div>
<div>86:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#&nbsp;WinCairo&nbsp;shares&nbsp;the&nbsp;auxiliary&nbsp;libs&nbsp;from&nbsp;the&nbsp;Apple&nbsp;port.</div>
<div>87:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;system("perl",&nbsp;"Tools/Scripts/update-webkit-wincairo-libs")&nbsp;==&nbsp;0&nbsp;or&nbsp;die;</div>
<div>88:&nbsp;&nbsp;&nbsp;&nbsp;}</div>
<div>89:}</div>
<div>&nbsp;</div>
<div>and I find the function "isAppleWinWebKit()" 
in&nbsp;&nbsp;WebKit-r170147\Tools\Scripts\webkitdirs.pm </div>
<div>&nbsp;</div>
<div>
<div>sub&nbsp;isAppleWinWebKit()</div>
<div>{</div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;return&nbsp;(isCygwin()&nbsp;||&nbsp;isWindows())&nbsp;&amp;&amp;&nbsp;!isWinCairo()&nbsp;&amp;&amp;&nbsp;!isGtk()&nbsp;&amp;&amp;&nbsp;!isWinCE();</div>
<div>}</div>
<div>&nbsp;</div>
<div>the problem is that&nbsp;isAppleWinWebKit() means !isWinCairo()&nbsp;,so 
the WebKit-r170147\Tools\Scripts\update-webkit line:85 is allways false.</div>
<div>why ? is it a problem?</div>
</div>
</div>
<div><span>256481788</span></div>
</div>
Trevor Linton | 23 Jun 05:53 2014
Picon

TextureMapper, TextureMapperGL and device scale factors

Hello,

I’m working on a port of webkit currently and haven’t been able to appropriately address hi-dpi device scale factors while using accelerated compositing with TextureMapper/TextureMapperGL (note i’m not using coordinated graphics and its running on a WebKit1 type interface). 

The issue is I don’t seem to see how to adjust the scale factor without creating all of the root graphics layers at twice the size, handle invalidation and setDisplayInRect in the device pixel size and subsequently start polluting or introducing the always fun issue of “is this pixel in device or logical pixels?” problem.

Is there some sort of way of implementing device scale factors in TextureMapper/TextureMapperGL? I’ve tried Page::setDeviceScaleFactor, Frame::tiledBackingStore()->setContentsScale.

I’ve also tried a patch I found recently for TextureMapper, but it required VERY carefully creating graphics layers, painting them and invalidating rects in different pixel coordinates (logical/device) depending on recursive conditions which makes things uber complicated.  In addition I never was able to get it working correctly with CSS3 animations (they’d typically render with half sized clips, or the x/y would be half size when the device scale factor was 2). 


At anyrate, i’m hoping someone here can help give me some background or guidance on how to start implementing this.  If the only option at the moment is facing the uphill “implement in texture mapper” problem i’m fine with it, i just want to make sure its the only approach to the issue since i’m not using coordinated compositor.

You can find my webcoresupport here:

And the platform API here:

- Trevor


<div>Hello,<div><br></div>
<div>I&rsquo;m working on a port of webkit currently and haven&rsquo;t been able to appropriately address hi-dpi device scale factors while using accelerated compositing with TextureMapper/TextureMapperGL (note i&rsquo;m not using coordinated graphics and its running on a WebKit1 type interface).&nbsp;</div>
<div><br></div>
<div>The issue is I don&rsquo;t seem to see how to adjust the scale factor without creating all of the root graphics layers at twice the size, handle invalidation and setDisplayInRect in the device pixel size and subsequently start polluting or introducing the always fun issue of &ldquo;is this pixel in device or logical pixels?&rdquo; problem.</div>
<div><br></div>
<div>Is there some sort of way of implementing device scale factors in TextureMapper/TextureMapperGL? I&rsquo;ve tried Page::setDeviceScaleFactor, Frame::tiledBackingStore()-&gt;setContentsScale.</div>
<div><br></div>
<div>I&rsquo;ve also tried a patch I found recently for TextureMapper, but it required VERY carefully creating graphics layers, painting them and invalidating rects in different pixel coordinates (logical/device) depending on recursive conditions which makes things uber complicated. &nbsp;In addition I never was able to get it working correctly with CSS3 animations (they&rsquo;d typically render with half sized clips, or the x/y would be half size when the device scale factor was 2).&nbsp;</div>
<div><br></div>
<div><a href="http://fishsoup.net/misc/webkit-hidpi-patches/0004-GTK-WK2-Implement-hi-dpi-support-for-accelerated-com.patch">http://fishsoup.net/misc/webkit-hidpi-patches/0004-GTK-WK2-Implement-hi-dpi-support-for-accelerated-com.patch</a></div>
<div><br></div>
<div>At anyrate, i&rsquo;m hoping someone here can help give me some background or guidance on how to start implementing this. &nbsp;If the only option at the moment is facing the uphill &ldquo;implement in texture mapper&rdquo; problem i&rsquo;m fine with it, i just want to make sure its the only approach to the issue since i&rsquo;m not using coordinated compositor.</div>
<div><br></div>
<div>You can find my webcoresupport here:</div>
<div><a href="https://github.com/trevorlinton/webkit.js/tree/master/src/WebCoreSupport">https://github.com/trevorlinton/webkit.js/tree/master/src/WebCoreSupport</a></div>
<div><br></div>
<div>And the platform API here:</div>
<div><a href="https://github.com/trevorlinton/webkit.js/blob/master/src/WebView.cpp">https://github.com/trevorlinton/webkit.js/blob/master/src/WebView.cpp</a></div>
<div><br></div>
<div>- Trevor</div>
<div><br></div>
<div><br></div>
</div>
Dan Wood | 19 Jun 04:15 2014

Stepping into webkit code in Xcode debugger

Hi folks, I haven’t been on the WebKit lists for several years!

I’m trying to track down some weird behavior with our app (Sandvox) which makes heavy use of WebKit
editing.  Many years ago we used to have a TOT build of WebKit that we would link to and embed in our app, but for
quite a while, we haven’t needed to do that.

So I’m kind of rusty about getting into the internals of WebKit!

I would like to be able to run our app in Xcode, and then step into Xcode, and have the debugger find the source
code to the WebKit, WebCore, etc. files.  I’d be OK with either having a version of the source code that
corresponds to the system-installed framework… or what I started was to build webkit, but now I’m not
sure what the next step is.

I’ve built webkit with build-webkit --debug and now it’s in my /build directory.  (That’s not the
build directory where my app and supporting frameworks are built; I wasn’t having any luck getting
set-webkit-configuration to work.)

Any suggestions for my next step, to get my app’s Xcode workspace to recognize my built webkit, and of
course link to it?  I assume by setting the DYLD_FRAMEWORK_PATH environment variable to /build/Debug
since that is where the built WebKit.framework lives.  Is that right?

I’m also a bit stuck because ever since I built WebKit, I’m now unable to build my app because for some
reason it’s not finding <WebKit/WebKit.h> for #import-ing anymore.  Any ideas how the building
scripts might have messed up the include paths in Xcode?  I added a -v to the clang statement and I am seeing
this directory in the #include <...> search list: 

/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks
(framework directory)

And that directory seems fine.  So it’s not clear why WebKit/WebKit.h wouldn’t be found any more.

Any clues that anybody might offer?

Thanks,

Dan Wood
Karelia Software

Luc R. | 19 Jun 02:13 2014
Picon

APIs for pre-injecting JavaScript

Hi, 

I am trying to find API which would allow to pre-inject a custom JavaScript before a web page content. Could anyone point to it? 

--
-Luc
<div><div dir="ltr">Hi,&nbsp;<div><br></div>
<div>I am trying to find API which would allow to pre-inject a custom JavaScript before a web page content. Could anyone point to it?&nbsp;<br clear="all"><div><br></div>-- <br>-Luc
</div>
</div></div>
avishkar gupta | 13 Jun 20:47 2014

cannot create a snapshot of WebKitWebView

hi,

I have the following code which compiles and runs successfully,however no matter what uri I choose I always get the error “There was an error creating the snapshot”. I would please request you to point out the problem with this code.

Please note that in order to run this code you need to provide a uri argument to webkit_web_view_load_uri.

I would have not posted this here but I could not find any coding samples or additional documentation available on said topic, other than the API docs.

thanks.

#include <webkit2/webkit2.h>
#include <gtk/gtk.h>

static void
snapshot_chain_cb(WebKitWebView *web_view,
      GAsyncResult* res,
      gpointer data)
{
 GError * err = NULL ;
 cairo_surface_t *surface = webkit_web_view_get_snapshot_finish(WEBKIT_WEB_VIEW(web_view),res,&err);
 if ( err )
 {
  printf("We have a problem.Specifically:%s\n",err->message);
 }
}

static void
cbfunc(WebKitWebView *webview,
  WebKitLoadEvent load_status,
  gpointer data)
{
 if ( load_status != WEBKIT_LOAD_FINISHED )
  return ;

 webkit_web_view_get_snapshot(webview,
         WEBKIT_SNAPSHOT_REGION_FULL_DOCUMENT,
         WEBKIT_SNAPSHOT_OPTIONS_INCLUDE_SELECTION_HIGHLIGHTING,
         NULL,
         (GAsyncReadyCallback)snapshot_chain_cb,
         NULL);
}

int main(int argc,char* argv[])
{
 gtk_init(&argc,&argv);
 GtkWidget* webview = webkit_web_view_new();
 GtkWidget* mainwindow = gtk_window_new(GTK_WINDOW_TOPLEVEL);
 GtkWidget* scrollable = gtk_scrolled_window_new(NULL,NULL);
 gtk_container_add(GTK_CONTAINER(mainwindow),scrollable);
 gtk_container_add(GTK_CONTAINER(scrollable),webview);

 webkit_web_view_load_uri(WEBKIT_WEB_VIEW(webview),"");

 g_signal_connect(webview,"load-changed",G_CALLBACK(cbfunc),NULL);
 gtk_main();
 return 0;
}
<div>
<div data-externalstyle="false" dir="ltr">
<div>hi,</div>
<div><br></div>
<div>I have the following code which compiles and runs successfully,however no matter what uri I choose I always get the error&nbsp;&ldquo;There was an error creating the snapshot&rdquo;. I would please request you to point out the problem with this code.</div>
<div><br></div>
<div>Please note that in order to&nbsp;run this code you need to provide a uri argument to webkit_web_view_load_uri.</div>
<div><br></div>
<div>I would have not posted this here but I could not find any coding samples or additional documentation&nbsp;available on said topic, other than the API docs.</div>
<div><br></div>
<div>thanks.</div>
<div><br></div>
<div>#include &lt;webkit2/webkit2.h&gt;<br>#include &lt;gtk/gtk.h&gt;</div>
<div><br></div>
<div>static void <br>snapshot_chain_cb(WebKitWebView *web_view,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; GAsyncResult* res,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; gpointer data)<br>{<br>&nbsp;GError * err = NULL ;<br>&nbsp;cairo_surface_t *surface = webkit_web_view_get_snapshot_finish(WEBKIT_WEB_VIEW(web_view),res,&amp;err);<br>&nbsp;if ( err )<br>&nbsp;{<br>&nbsp;&nbsp;printf("We have a problem.Specifically:%s\n",err-&gt;message);<br>&nbsp;}<br>}</div>
<div><br></div>
<div>static void <br>cbfunc(WebKitWebView *webview,<br>&nbsp;&nbsp;WebKitLoadEvent load_status,<br>&nbsp;&nbsp;gpointer data)<br>{<br>&nbsp;if ( load_status != WEBKIT_LOAD_FINISHED )<br>&nbsp;&nbsp;return ;</div>
<div><br></div>
<div>&nbsp;webkit_web_view_get_snapshot(webview,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; WEBKIT_SNAPSHOT_REGION_FULL_DOCUMENT,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; WEBKIT_SNAPSHOT_OPTIONS_INCLUDE_SELECTION_HIGHLIGHTING,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; NULL,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (GAsyncReadyCallback)snapshot_chain_cb,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; NULL);<br>}</div>
<div><br></div>
<div>int main(int argc,char* argv[])<br>{<br>&nbsp;gtk_init(&amp;argc,&amp;argv);<br>&nbsp;GtkWidget* webview = webkit_web_view_new();<br>&nbsp;GtkWidget* mainwindow = gtk_window_new(GTK_WINDOW_TOPLEVEL);<br>&nbsp;GtkWidget* scrollable = gtk_scrolled_window_new(NULL,NULL);<br>&nbsp;gtk_container_add(GTK_CONTAINER(mainwindow),scrollable);<br>&nbsp;gtk_container_add(GTK_CONTAINER(scrollable),webview);</div>
<div><br></div>
<div>&nbsp;webkit_web_view_load_uri(WEBKIT_WEB_VIEW(webview),"");</div>
<div><br></div>
<div>&nbsp;g_signal_connect(webview,"load-changed",G_CALLBACK(cbfunc),NULL);<br>&nbsp;gtk_main();<br>&nbsp;return 0;<br>}<br>
</div>
</div>
</div>
孙玉婷 | 4 Jun 06:45 2014
Picon

webkit keep request resource for same url when it's blocked manually by design

Hi Benjamin or other expert

Do you happen to know why webkit keep request resource for same url 1000+ or even 10000+ when it's blocked manually by design?

Like when rendering http://sg.88db.com/q-Fibre+Optic+Cable/1/, in my case, it requests http://sg.88db.com/sg/images/img_noImg.jpg 1000+ times.

I am wordering is this some kind of retry or preloading or something else?

thanks for your help in advance.
<div><div dir="ltr">Hi Benjamin or other expert<div><br></div>
<div>Do you happen to know why webkit keep request resource for same url 1000+ or even 10000+ when it's blocked manually by design?</div>
<div><br></div>
<div>Like when rendering <a href="http://sg.88db.com/q-Fibre+Optic+Cable/1/">http://sg.88db.com/q-Fibre+Optic+Cable/1/</a>, in my case, it requests&nbsp;<a href="http://sg.88db.com/sg/images/img_noImg.jpg">http://sg.88db.com/sg/images/img_noImg.jpg</a> 1000+ times.</div>
<div><br></div>
<div>I am wordering is this some kind of retry or preloading or something else?</div>
<div><br></div>
<div>thanks for your help in advance.</div>
</div></div>
Victor Lucero | 25 May 00:05 2014
Picon

Re: resource-request-starting and never match

Oh. im sorry.
so insted if you allow me to ask something directly in relation with webkit.

can i use the webkit api directly wihtout the need of safari, gtk3 or qt?

I mean. Is the webkitapi is exposed directly in some way so I can use it without depending of gtk,qt or any
other gui api?

Best regards.
Victor Lucero.

El 23-05-2014, a las 18:56, Benjamin Poulain <benjamin@...> escribió:

> Hi Victor,
> 
> On 5/23/14, 3:24 PM, Victor Lucero wrote:
>> Hi.
>> Im used webkit throught 1.8.3 to webkitgtk3-2.2.7
>> 
>> and the signal resource-request-starting never match the amount of resource-resource-load-finished
>> like there are resources that arent reported as finished.
>> 
>> I also attach events to soupsesion to see every request but they never match, and the diference is very big.
>> 
>> just tested a regular site and resource-request-starting reported 96 elements but of those only 65
reported resource-resource-load-finished(the elements reported trought the soupsession almot
match the ones reported via resource-request-starting )
>> 
>> I tested a lot of sites and the number are always like this.
>> 
>> I also tried to attach events to the soupmessage that comes trought the signal
"resource-request-starting" but i was looking at the rource and looks like webkitgtk just use it as
reference using "updateFromSoupMessage".
>> 
>> can you guideme to a way to know all the elements that finished loading ?
> 
> This is a webkit-gtk question, you will have better luck on the WebKit-GTK mailing list (https://lists.webkit.org/mailman/listinfo/webkit-gtk).
> 
> Benjamin
> 
> _______________________________________________
> webkit-help mailing list
> webkit-help@...
> https://lists.webkit.org/mailman/listinfo/webkit-help

Eric Wing | 16 May 13:33 2014
Picon

JavaScriptCore: How can I create a private strong reference list for a JSObjectRef using the C-API

From the C-API, I have a JSObjectRef. What I want is for my
JSObjectRef to have a private table/array which holds other
JSObjectRefs. Basically, I want a strong reference list so any objects
in that list won't be collected until after my object is collected.

My initial implementation was to create a standard C-array which held
the JSObjectRef's for my list. I used JSValueProtect on each element
as I added them to my array. My plan was to then call JSValueUnprotect
for each item in my array in the finalizer. However, I discovered that
I don't get the context in the finalizer callback and I'm not supposed
to call any functions that use a context.

Can you suggest how I should implement this instead? (Or if I can
somehow get the context, will this finalizer solution work anyway?)

I started looking at the objectDefinition.staticValues and the
JSObjectGetProperty/JSObjectSetProperty and their callbacks, thinking
I could use JSObjectMakeArray with this to hold my references instead
of using JSValueProtect. But I don't understand how the life-cycle
management deals with anything I write in these callback functions, so
I don't know if this will work.

Thanks,
Eric
--

-- 
Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/

Gmane