[webkit-dev] "highlighting" a frame

Simon Fraser simon.fraser at apple.com
Tue Jul 17 13:00:08 PDT 2012


Actually this is possible, using a negative outline-offset:

<style>
iframe {
outline: 10px solid orange;
outline-offset: -10px;
}
</style>
<iframe></iframe

On Jul 17, 2012, at 10:55 AM, Simon Fraser <simon.fraser at apple.com> wrote:

> I think what you really want is a border that shows *inside* the frame bounds, but over all of the content in that frame. There isn't really a mechanism to draw things like this currently.
> 
> Simon
> 
> On Jul 17, 2012, at 10:44 AM, Patrick East <patricke at bsquare.com> wrote:
> 
>> Thank for the suggestion, I found that using the outline style on a frame and iframe :hover selector only seemed to work on iframes and not frames in a frameset. I’ve attached a sample that shows the problem, if you’re curious to see what happens. If you look at the frameset.html page and mouse over the bottom frame that contains an iframe, the border style is the only one that shows up, and it is on the outermost frame in the frameset gets a border in addition to the iframe.
>>  
>> I suspect the behavior we are trying to get isn’t really achievable with just the default html.css styling. We are going to look into using the focus ring mechanism as James MacLean suggested earlier.
>>  
>>  
>> Patrick East
>> patricke at bsquare.com
>>  
>> From: Elliott Sprehn [mailto:esprehn at google.com] 
>> Sent: Monday, July 16, 2012 12:54 PM
>> To: Patrick East
>> Cc: webkit-dev at lists.webkit.org
>> Subject: Re: [webkit-dev] "highlighting" a frame
>>  
>> You'll want outline not border for this.
>>  
>>  
>> From: wjmaclean at google.com [mailto:wjmaclean at google.com] On Behalf Of W. James MacLean
>> Sent: Wednesday, July 11, 2012 1:09 PM
>> To: Patrick East
>> Cc: webkit-dev at lists.webkit.org
>> Subject: Re: [webkit-dev] "highlighting" a frame
>>  
>> If you're just looking to draw a border, will the focus rings mechanism suffice?
>>  
>>  
>> On Mon, Jul 9, 2012 at 10:37 PM, Patrick East <patricke at bsquare.com> wrote:
>> Hello,
>>  
>> We are working on a custom build of WebKit that will "highlight" a frame when the mouse moves over it (the intent is to have it draw a border around it for use with a custom input device). We have tried modifying the webcore html.css file adding in a :hover selector for frame and iframe that sets the border property, but this doesn't work correctly for embedded frames. When we test mousing over them it draws the border on the outer-most frame and not the inner frame which is what I want.
>>  
>> Unfortunately I don't know much about the css code in WebKit, so any suggestions on how this could be achieved would be much appreciated. 
>>  
>> Thanks!
>>  
>> Patrick East
>> patricke at bsquare.com
>> 
>> _______________________________________________
>> webkit-dev mailing list
>> webkit-dev at lists.webkit.org
>> http://lists.webkit.org/mailman/listinfo/webkit-dev
>> 
>>  
>> <frameset.html><links.html><spatial-navigation-test-cases - iframe_outline.html>_______________________________________________
>> webkit-dev mailing list
>> webkit-dev at lists.webkit.org
>> http://lists.webkit.org/mailman/listinfo/webkit-dev
> 
> _______________________________________________
> webkit-dev mailing list
> webkit-dev at lists.webkit.org
> http://lists.webkit.org/mailman/listinfo/webkit-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20120717/124da087/attachment.html>


More information about the webkit-dev mailing list