[chromium-dev] How to add logging support to chromium
I want to log something from within webkit and have it show up in Chrome's log. This seemingly basic operation seems to be unsupported in chromium's version of webkit? First off, WebKit does have WTFLogging facilities (see logging.h and assertions.h) which are similar to our LOG(XXX) faciities. There appears to be no way to turn these on within the chromium build, because we don't implement nor call the initialization routine (InitializeLoggingChannelsIfNecessary()). OK - I can implement that.. But next, I want the logging to actually go to chrome's log file. The function to change is Assertions.cpp:vprintf_stderr_common(). I can add an if PLATFORM(CHROMIUM) here, and that would work, but how can I call code back in chromium's base? I don't think I can do this? It seems I should add something to WebKit/WebCore/platform/chromium/ but - any references to base won't work, right? The README from webkit/api specifically says I can't use base code (std types) in the chromium bridge. What is the right way to do this? Mike --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] hammer base_unittests failed
chrome[26-06:27:20]/home/chrome/src/basehammer base_unittests scons: Reading SConscript files ... scons: done reading SConscript files. scons: Building targets ... Extracting last change to /home/chrome/src/sconsbuild/Debug/obj/ _global_intermediate/build/LASTCHANGE Compiling /home/chrome/src/sconsbuild/Debug/obj/skia/ext/ bitmap_platform_device_linux.o Compiling /home/chrome/src/sconsbuild/Debug/obj/skia/ext/ platform_canvas.o /home/chrome/src/skia/ext/bitmap_platform_device_linux.cc: In static member function 'static skia::BitmapPlatformDevice* skia::BitmapPlatformDevice::Create(int, int, bool, uint8_t*)': /home/chrome/src/skia/ext/bitmap_platform_device_linux.cc:171: error: 'cairo_format_stride_for_width' was not declared in this scope scons: *** [/home/chrome/src/sconsbuild/Debug/obj/skia/ext/ bitmap_platform_device_linux.o] Error 1 Creating library /home/chrome/src/sconsbuild/Debug/lib/libbase.a Indexing /home/chrome/src/sconsbuild/Debug/lib/libbase.a scons: building terminated because of errors. --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] gclient run failed.
running 'svn update /home/chrome/src/chrome/test/data/workers/ LayoutTests/http/tests/workers --revision 46087' in '/home/chrome' svn: PROPFIND request failed on '/repository/webkit/trunk/LayoutTests/ http/tests/workers' svn: PROPFIND of '/repository/webkit/trunk/LayoutTests/http/tests/ workers': could not connect to server (http://svn.webkit.org) Error: failed to run command: svn update /home/chrome/src/chrome/test/ data/workers/LayoutTests/http/tests/workers --revision 46087 chrome[26-06:34:46]/home/chrome/l /repository/webkit/trunk/ LayoutTests/http/tests/workers ls: /repository/webkit/trunk/LayoutTests/http/tests/workers: No such file or directory chrome[26-06:37:36]/home/chrome/ --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: hammer base_unittests failed
On Sun, Jul 19, 2009 at 10:15 AM, empriserxueyunl...@gmail.com wrote: /home/chrome/src/skia/ext/bitmap_platform_device_linux.cc: In static member function 'static skia::BitmapPlatformDevice* skia::BitmapPlatformDevice::Create(int, int, bool, uint8_t*)': /home/chrome/src/skia/ext/bitmap_platform_device_linux.cc:171: error: 'cairo_format_stride_for_width' was not declared in this scope scons: *** [/home/chrome/src/sconsbuild/Debug/obj/skia/ext/ bitmap_platform_device_linux.o] Error 1 A little googling shows that this can be caused by having a too-old version of libcairo2 ( http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=510750 https://trac.osgeo.org/grass/ticket/419 ) What version of what OS are you building on, and what version of libcairo2 does it have? I think the minimum version needed is 1.6. - Dan --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Getting Started with a New Project
For the purposes of practice I am trying to create an empty Win32 Exe project that uses the demonstration code from: http://dev.chromium.org/developers/design-documents/chromeviews To do this I have created a new solution and an empty project. I have then added the demonstration code, and in the project settings added the additional include/lib directories (which I copied from an Exe project from the Chromium trunk). However, when I try to build the project, I get the following compilation error: 1c:\chromium\src\quick_test\quick_test\views\main_window.cc(4) : fatal error C1083: Cannot open include file: 'chrome/common/gfx/ chrome_canvas.h': No such file or directory What steps are required to create a new solution/project of this nature? I would really like to use the views API that Chromium has to offer. Many thanks, Lea Hayes --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] What's the deal with document tags?
I'm working on implementing the OS X spelling panel for chromium and I was wondering about document tags (a unique tag for every spellcheckable thing). These tags are needed in order to support ignoring words, which the spelling panel has a button for. It looks like there is some support for it in webkit (the method Editor::spellCheckerDocumentTag defers to EditorClientImpl which has the it marked as NOTIMPLEMENTED()). The problem is that Editor::spellCheckerDocumentTag doesn't seem to ever get called (or at least, a breakpoint in the renderer at that line doesn't get hit on a page with an editable textarea element). The tags themselves are pretty easy to generate (NSSpellChecker has a method to do it), but I'm a bit lost as to how they work in webkit. So, if anybody knows anything about how these are supposed to work, that would be awesome. Thanks, -Paul Wicks --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: Getting Started with a New Project
Did you added the common project to your solution? On Jul 19, 12:40 pm, Kruncher leaha...@gmail.com wrote: For the purposes of practice I am trying to create an empty Win32 Exe project that uses the demonstration code from: http://dev.chromium.org/developers/design-documents/chromeviews To do this I have created a new solution and an empty project. I have then added the demonstration code, and in the project settings added the additional include/lib directories (which I copied from an Exe project from the Chromium trunk). However, when I try to build the project, I get the following compilation error: 1c:\chromium\src\quick_test\quick_test\views\main_window.cc(4) : fatal error C1083: Cannot open include file: 'chrome/common/gfx/ chrome_canvas.h': No such file or directory What steps are required to create a new solution/project of this nature? I would really like to use the views API that Chromium has to offer. Many thanks, Lea Hayes --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Chromium crash
When I start typing in omnibox from Chromium (I'm debugging) the browser crashes... I'm getting this error: [2148:3796:1738765:FATAL:autocomplete.cc(438)] Check failed: classification.size() == 0, Error initializing symbols(0). Dumping unresolved backtrace: --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: How to add logging support to chromium
Thanks, Jeremy. Are you sure this is right? I don't think so. First, the README in WebKit/api says, BASIC TYPES Use of STL is prohibited except in cases where it would be allowed in WebCore. This includes non-allocating uses: algorithms, numeric limits, etc. WTF container classes should be used in the implementation of this API. The API includes some usage of WebCore types when WEBKIT_IMPLEMENTATION is defined. This is only done for the convenience to the implementation, and should not be considered part of the Chromium WebKit API. Similarly, STL types are assumed when WEBKIT_IMPLEMENTATION is not defined, which is done for the convenience of the consumer. That's a pretty clear condemnation of anything in base, right? Also, I'm not allowed to just do a #include of WebKitClient.h from WebKit code, right? Or do I just do that under an ifdef? Mike On Sun, Jul 19, 2009 at 1:41 PM, Jeremy Orlow jor...@chromium.org wrote: Take a look at src/webkit/api/public. WebKitClient has all the hooks back into Chromium. src/chrome/renderer/renderer_webkitclient_impl.h implements the WebKitClient interface. I'm not exactly sure how you want to design the interface. If it's just a function or two and you don't need to maintain any state, then you can just add functions directly to the WebKitClient. If you need anything more complicated, you should create a new interface in src/webkit/api/public and add a function to WebKitClient that creates an instance of it. Patch set 8 here http://codereview.chromium.org/147248 might be a good reference for how to use them. (There's a lot there, but I think it should be obvious which files you don't care about.) For calling to the WebKitClient functions, you have two options. You can either implement WebCore:: functions in src/webkit/api/src or you can make your webcore/platform/chromium code call ChromiumBridge. If you can do the former cleanly, I think it's the preferred approach. The above CL does it the latter way in src/webkit/api/src/StorageNamespaceProxy.h. J On Sun, Jul 19, 2009 at 12:21 AM, Mike Belshe mbel...@google.com wrote: I want to log something from within webkit and have it show up in Chrome's log. This seemingly basic operation seems to be unsupported in chromium's version of webkit? First off, WebKit does have WTFLogging facilities (see logging.h and assertions.h) which are similar to our LOG(XXX) faciities. There appears to be no way to turn these on within the chromium build, because we don't implement nor call the initialization routine (InitializeLoggingChannelsIfNecessary()). OK - I can implement that.. But next, I want the logging to actually go to chrome's log file. The function to change is Assertions.cpp:vprintf_stderr_common(). I can add an if PLATFORM(CHROMIUM) here, and that would work, but how can I call code back in chromium's base? I don't think I can do this? It seems I should add something to WebKit/WebCore/platform/chromium/ but - any references to base won't work, right? The README from webkit/api specifically says I can't use base code (std types) in the chromium bridge. What is the right way to do this? Mike --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: How to add logging support to chromium
You add a function definition to the WebKitClient interface, but then the implementation of the interface is in the renderer code. The renderer code would then make the actual call to base. When the renderer is initializing, it creates an instance of its WebKitClient implementation (src/chrome/renderer/renderer_webkitclient_impl.cc) and passes it into WebKit (via the initialize function in src/webkit/api/public/WebKit.h if I remember correctly..the .cpp file is in src/webkit/api/src/). By either implementing your WebCore functions in src/webkit/api/src or using ChromiumBridge, you can call the WebKitClient functions. I'm pretty positive this is right. Although not all of the code has landed or had its final review yet, most of the code in the CL I listed earlier has been reviewed by Darin. J On Sun, Jul 19, 2009 at 2:11 PM, Mike Belshe mbel...@google.com wrote: Thanks, Jeremy. Are you sure this is right? I don't think so. First, the README in WebKit/api says, BASIC TYPES Use of STL is prohibited except in cases where it would be allowed in WebCore. This includes non-allocating uses: algorithms, numeric limits, etc. WTF container classes should be used in the implementation of this API. The API includes some usage of WebCore types when WEBKIT_IMPLEMENTATION is defined. This is only done for the convenience to the implementation, and should not be considered part of the Chromium WebKit API. Similarly, STL types are assumed when WEBKIT_IMPLEMENTATION is not defined, which is done for the convenience of the consumer. That's a pretty clear condemnation of anything in base, right? Also, I'm not allowed to just do a #include of WebKitClient.h from WebKit code, right? Or do I just do that under an ifdef? Mike On Sun, Jul 19, 2009 at 1:41 PM, Jeremy Orlow jor...@chromium.org wrote: Take a look at src/webkit/api/public. WebKitClient has all the hooks back into Chromium. src/chrome/renderer/renderer_webkitclient_impl.h implements the WebKitClient interface. I'm not exactly sure how you want to design the interface. If it's just a function or two and you don't need to maintain any state, then you can just add functions directly to the WebKitClient. If you need anything more complicated, you should create a new interface in src/webkit/api/public and add a function to WebKitClient that creates an instance of it. Patch set 8 here http://codereview.chromium.org/147248 might be a good reference for how to use them. (There's a lot there, but I think it should be obvious which files you don't care about.) For calling to the WebKitClient functions, you have two options. You can either implement WebCore:: functions in src/webkit/api/src or you can make your webcore/platform/chromium code call ChromiumBridge. If you can do the former cleanly, I think it's the preferred approach. The above CL does it the latter way in src/webkit/api/src/StorageNamespaceProxy.h. J On Sun, Jul 19, 2009 at 12:21 AM, Mike Belshe mbel...@google.com wrote: I want to log something from within webkit and have it show up in Chrome's log. This seemingly basic operation seems to be unsupported in chromium's version of webkit? First off, WebKit does have WTFLogging facilities (see logging.h and assertions.h) which are similar to our LOG(XXX) faciities. There appears to be no way to turn these on within the chromium build, because we don't implement nor call the initialization routine (InitializeLoggingChannelsIfNecessary()). OK - I can implement that.. But next, I want the logging to actually go to chrome's log file. The function to change is Assertions.cpp:vprintf_stderr_common(). I can add an if PLATFORM(CHROMIUM) here, and that would work, but how can I call code back in chromium's base? I don't think I can do this? It seems I should add something to WebKit/WebCore/platform/chromium/ but - any references to base won't work, right? The README from webkit/api specifically says I can't use base code (std types) in the chromium bridge. What is the right way to do this? Mike --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: Chromium crash
On Sun, Jul 19, 2009 at 12:52 PM, Thiago Farina thiago.far...@gmail.comwrote: When I start typing in omnibox from Chromium (I'm debugging) the browser crashes... Since yo're debugging, you can track down what's going on. Then you can look it up in the bug database. PK --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: How to add logging support to chromium
On Sun, Jul 19, 2009 at 2:26 PM, Jeremy Orlow jor...@chromium.org wrote: You add a function definition to the WebKitClient interface, but then the implementation of the interface is in the renderer code. The renderer code would then make the actual call to base. When the renderer is initializing, it creates an instance of its WebKitClient implementation (src/chrome/renderer/renderer_webkitclient_impl.cc) and passes it into WebKit (via the initialize function in src/webkit/api/public/WebKit.h if I remember correctly..the .cpp file is in src/webkit/api/src/). By either implementing your WebCore functions in src/webkit/api/src or using ChromiumBridge, you can call the WebKitClient functions. I'm pretty positive this is right. Although not all of the code has landed or had its final review yet, most of the code in the CL I listed earlier has been reviewed by Darin. ok - thanks for the explanation. sounds like this could work. I misunderstood the comment in the readme. Mike J On Sun, Jul 19, 2009 at 2:11 PM, Mike Belshe mbel...@google.com wrote: Thanks, Jeremy. Are you sure this is right? I don't think so. First, the README in WebKit/api says, BASIC TYPES Use of STL is prohibited except in cases where it would be allowed in WebCore. This includes non-allocating uses: algorithms, numeric limits, etc. WTF container classes should be used in the implementation of this API. The API includes some usage of WebCore types when WEBKIT_IMPLEMENTATION is defined. This is only done for the convenience to the implementation, and should not be considered part of the Chromium WebKit API. Similarly, STL types are assumed when WEBKIT_IMPLEMENTATION is not defined, which is done for the convenience of the consumer. That's a pretty clear condemnation of anything in base, right? Also, I'm not allowed to just do a #include of WebKitClient.h from WebKit code, right? Or do I just do that under an ifdef? Mike On Sun, Jul 19, 2009 at 1:41 PM, Jeremy Orlow jor...@chromium.orgwrote: Take a look at src/webkit/api/public. WebKitClient has all the hooks back into Chromium. src/chrome/renderer/renderer_webkitclient_impl.h implements the WebKitClient interface. I'm not exactly sure how you want to design the interface. If it's just a function or two and you don't need to maintain any state, then you can just add functions directly to the WebKitClient. If you need anything more complicated, you should create a new interface in src/webkit/api/public and add a function to WebKitClient that creates an instance of it. Patch set 8 here http://codereview.chromium.org/147248 might be a good reference for how to use them. (There's a lot there, but I think it should be obvious which files you don't care about.) For calling to the WebKitClient functions, you have two options. You can either implement WebCore:: functions in src/webkit/api/src or you can make your webcore/platform/chromium code call ChromiumBridge. If you can do the former cleanly, I think it's the preferred approach. The above CL does it the latter way in src/webkit/api/src/StorageNamespaceProxy.h. J On Sun, Jul 19, 2009 at 12:21 AM, Mike Belshe mbel...@google.comwrote: I want to log something from within webkit and have it show up in Chrome's log. This seemingly basic operation seems to be unsupported in chromium's version of webkit? First off, WebKit does have WTFLogging facilities (see logging.h and assertions.h) which are similar to our LOG(XXX) faciities. There appears to be no way to turn these on within the chromium build, because we don't implement nor call the initialization routine (InitializeLoggingChannelsIfNecessary()). OK - I can implement that.. But next, I want the logging to actually go to chrome's log file. The function to change is Assertions.cpp:vprintf_stderr_common(). I can add an if PLATFORM(CHROMIUM) here, and that would work, but how can I call code back in chromium's base? I don't think I can do this? It seems I should add something to WebKit/WebCore/platform/chromium/ but - any references to base won't work, right? The README from webkit/api specifically says I can't use base code (std types) in the chromium bridge. What is the right way to do this? Mike --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: Chromium crash
Hi Peter, How can I track down? Where is bug database located? In the Local\Chromium\User Data\Crash Reports directory, there is nothing. Thanks! On Jul 19, 6:33 pm, Peter Kasting pkast...@google.com wrote: On Sun, Jul 19, 2009 at 12:52 PM, Thiago Farina thiago.far...@gmail.comwrote: When I start typing in omnibox from Chromium (I'm debugging) the browser crashes... Since yo're debugging, you can track down what's going on. Then you can look it up in the bug database. PK --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: Chromium crash
On Sun, Jul 19, 2009 at 2:43 PM, Thiago Farina thiago.far...@gmail.comwrote: How can I track down? Using your handy debugger, to see what's going on. If you don't know how to debug code, you're probably not going to be well-served by trying to get low-level details from this mailing list. Where is bug database located? In the Local\Chromium\User Data\Crash Reports directory, there is nothing. crbug.com PK --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---
[chromium-dev] Re: Chromium crash
I thought this problem was known. Thanks! On Jul 19, 6:33 pm, Peter Kasting pkast...@google.com wrote: On Sun, Jul 19, 2009 at 12:52 PM, Thiago Farina thiago.far...@gmail.comwrote: When I start typing in omnibox from Chromium (I'm debugging) the browser crashes... Since yo're debugging, you can track down what's going on. Then you can look it up in the bug database. PK --~--~-~--~~~---~--~~ Chromium Developers mailing list: chromium-dev@googlegroups.com View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-dev -~--~~~~--~~--~--~---