[webkit-dev] YARR example

2013-01-03 Thread Ognian Milanov
Hello! I need info how to use YARR to replace all matches of a given regular expression in a string with another string. For example in Java this is achieved by String.replaceAll method. I will appreciate if someone leads me to the solution, thanks! ___

Re: [webkit-dev] YARR example

2013-01-03 Thread Michael Saboff
Ognian, YARR is the regular expression engine for the JavaScriptCore part of webkit. It can find the matches, but you would need to write other C++ code to do the replacement. The String.replace() method will do what you want in JavaScript. - Michael On Jan 3, 2013, at 4:16 AM, Ognian

Re: [webkit-dev] Int/FloatPoint and Int/FloatSize

2013-01-03 Thread Shawn Singh
Personally I like the idea of removing the subtraction operator (point minus point returns size) and make it explicit. *** However ***, if we change the data type of objects from Size to Point, we have to be careful to check whether they are ever mapped by transforms. In particular, Points use

Re: [webkit-dev] Int/FloatPoint and Int/FloatSize

2013-01-03 Thread Peter Kasting
On Thu, Jan 3, 2013 at 11:36 AM, Shawn Singh shawnsi...@chromium.orgwrote: Cons of making a separate vector class: - offsets are sometimes treated as relative point locations, and other times treated as vectors that can be added to points. Deciding when to use which one could become just

Re: [webkit-dev] Int/FloatPoint and Int/FloatSize

2013-01-03 Thread Stephen Chenney
On Thu, Jan 3, 2013 at 3:14 PM, Peter Kasting pkast...@google.com wrote: On Thu, Jan 3, 2013 at 11:36 AM, Shawn Singh shawnsi...@chromium.orgwrote: Cons of making a separate vector class: - offsets are sometimes treated as relative point locations, and other times treated as vectors that

Re: [webkit-dev] Proposal: Add webkitFillRule to canvas

2013-01-03 Thread Ian Hickson
On Wed, 2 Jan 2013, James Ascroft-Leigh wrote: There has been a proposal that a new property is added to the canvas 2D drawing context called fillRule with values nonzero (default) and evenodd. This is compatible with the mozFillRule already implemented in Mozilla Firefox and would be on

Re: [webkit-dev] Int/FloatPoint and Int/FloatSize

2013-01-03 Thread Steve Block
Thanks all for the detailed replies. I wasn't aware of the distinction made between points and vectors for the purposes transforms. However, if I understand things correctly, introducing a vector type could be considered separately from the issue I initially raised. It seems that everyone is

Re: [webkit-dev] Int/FloatPoint and Int/FloatSize

2013-01-03 Thread Simon Fraser
On Jan 3, 2013, at 7:43 PM, Steve Block wrote: Thanks all for the detailed replies. I wasn't aware of the distinction made between points and vectors for the purposes transforms. However, if I understand things correctly, introducing a vector type could be considered separately from the

Re: [webkit-dev] Int/FloatPoint and Int/FloatSize

2013-01-03 Thread Mike Lawther
On 4 January 2013 16:15, Simon Fraser simon.fra...@apple.com wrote: Introducing the concept of a vector could then be done in a second phase. What would you call this type, avoiding confusion with Vector? Rename that to DynamicallyResizableRandomlyAccessibleT, because, you know, Euclid got

Re: [webkit-dev] Int/FloatPoint and Int/FloatSize

2013-01-03 Thread Steve Block
I find point - point = size quite useful in general, and it seems to make logical sense. I agree that it makes logical sense, but I think that 'point - point = point' also makes sense, and is perhaps more frequently the right choice. What would you call this type, avoiding confusion with