Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement clear #673

Merged
merged 2 commits into from Aug 5, 2013
Merged

Implement clear #673

merged 2 commits into from Aug 5, 2013

Conversation

@sanxiyn
Copy link
Contributor

sanxiyn commented Aug 5, 2013

No description provided.

@sanxiyn
Copy link
Contributor Author

sanxiyn commented Aug 5, 2013

Will add a commit to update submodules when servo/rust-netsurfcss#19 and servo/rust-css#23 are merged.


noncontent_height = base.model.padding.top + base.model.padding.bottom +
base.model.border.top + base.model.border.bottom;
base.position.size.height = height + noncontent_height;

noncontent_height = noncontent_height + base.model.margin.top + base.model.margin.bottom;
noncontent_height = noncontent_height + clearance + base.model.margin.top + base.model.margin.bottom;

This comment has been minimized.

Copy link
@metajack

metajack Aug 5, 2013

Contributor

It feels wrong to have clearance included in the height. It now makes the variable name wrong, since this is no longer the noncontent height, but noncontent height plus some other things.

I'd like to figure out some better way to include clearance.

@metajack
Copy link
Contributor

metajack commented Aug 5, 2013

pinging @eric93

@eric93
Copy link

eric93 commented Aug 5, 2013

Looks good to me. The only thought I had is that it may be worthwhile to memoize calls to clearance() by storing the values in the float context itself. We would need to update them whenever a float is added but reading them would be fast and simple.

@metajack
Copy link
Contributor

metajack commented Aug 5, 2013

@eric93 any thoughts on if clearance should go in FlowData to address my comments?

@eric93
Copy link

eric93 commented Aug 5, 2013

@metajack I think we should avoid putting things in FlowData unless they must be stored. It seems to me that clearance does have to be added to the height at some point, so the question is whether it's okay to put it under noncontent_height. I don't really have a strong opinion either way on this.

@metajack

This comment has been minimized.

Copy link

metajack commented on 23874eb Aug 5, 2013

r+

@metajack
Copy link
Contributor

metajack commented Aug 5, 2013

After thinking about this more I'm r+ing it.

Great work!

@bors-servo

This comment has been minimized.

Copy link
Contributor

bors-servo commented on 23874eb Aug 5, 2013

saw approval from metajack
at sanxiyn@23874eb

This comment has been minimized.

Copy link
Contributor

bors-servo replied Aug 5, 2013

merging sanxiyn/servo/clear = 23874eb into auto

This comment has been minimized.

Copy link
Contributor

bors-servo replied Aug 5, 2013

sanxiyn/servo/clear = 23874eb merged ok, testing candidate = 63e7866

This comment has been minimized.

Copy link
Contributor

bors-servo replied Aug 5, 2013

fast-forwarding master to auto = 63e7866

bors-servo pushed a commit that referenced this pull request Aug 5, 2013
@bors-servo bors-servo merged commit 23874eb into servo:master Aug 5, 2013
1 check passed
1 check passed
default all tests passed
@BrendanEich
Copy link

BrendanEich commented Aug 5, 2013

Thanks, Seo!

/be

ChrisParis pushed a commit to ChrisParis/servo that referenced this pull request Sep 7, 2014
Categorize a few media tests into spec section directories
glennw pushed a commit to glennw/servo that referenced this pull request Jan 16, 2017
Remove clip_clear and rectangle_noblend from the clip batcher.

Now that clip masks are stored in the red channel, we can just
clear the intermediate targets to (1,0,0,0). This satisfies the
requirement of clip masks being initialized to 1, while also
allowing the alpha component to be initialized to 0 for visual
render tasks that rely on it.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/webrender/673)
<!-- Reviewable:end -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.