Commit Graph

174 Commits

Author SHA1 Message Date
L. David Baron
54995e2a8e Remove width determination parameters from font inflation methods. (Bug 747720, patch 5) r=roc
These are no longer needed since we're getting the width from the
nsFontInflationData.
2012-05-20 22:18:28 -07:00
Robert O'Callahan
d0dd680745 Bug 733607. Restructure logic to compute snapped bounds of display items in layer coordinates. Moves responsibility for computing snapped bounds from within the display items to callers of GetBounds/GetOpaqueRegion. r=tnikkel
Previously we snapped the results of nsDisplayItem::GetBounds and
nsDisplayItem::GetOpaqueRegion internally. By tracking which display items were
inside transforms, we disabled snapping quite conservatively whenever an ancestor
had a transform, which is undesirable.

With this patch, we don't snap inside GetBounds or GetOpaqueRegion, but just return
a boolean flag indicating whether the item will draw with snapping or not. This flag
is conservative so that "true" means we will snap (if the graphics context has a transform
that allows snapping), but "false" means we might or might not snap (so it's always safe
to return false).

FrameLayerBuilder takes over responsibility for snapping item bounds. When it converts
display item bounds to layer pixel coordinates, it checks the snap flag returned from
the display item and checks whether the transform when we draw into the layer will be
a known scale (the ContainerParameters scale factors) plus integer translation. If both
are true, we snap the item bounds when converting to layer pixel coordinates. With
this approach, we can snap item bounds even when the items have ancestors with active
transforms.
2012-04-10 23:24:18 +12:00
L. David Baron
5eb8920348 Switch nsLayoutUtils inflation methods to the new setup with state on the pres context. (Bug 706609, patch 5) r=roc
This is the third of three patches to rework the way we handle getting
the font inflation container and width data during reflow, which are
needed so that we can sometimes honor inflation during intrinsic width
calculation (which we need to do to make some form controls inflate
correctly).
2012-01-24 17:21:29 -08:00
Kyle Huey
9cc71b5f7f Bug 714752: Make imgIContainerObserver::FrameChanged take an imgIRequest*. r=joe sr=roc 2012-01-06 07:32:38 -05:00
Mats Palmgren
9cc6cc3865 Bug 515530 - Remove nsHTMLContainerFrame. r=roc 2011-12-27 21:18:48 +01:00
Ms2ger
294b93eff9 Bug 709509 - Remove manual refcounting and QIing from nsBulletFrame::DidSetStyleContext; r=dbaron 2011-12-24 09:28:23 +01:00
L. David Baron
b4141b61eb Apply font size inflation to list bullets. (Bug 627842, patch 13) r=roc
Note that this doesn't do anything about the indentation of the list, so
for large inflation there may end up being overlap as a result.
2011-11-23 18:48:23 -08:00
Scott Johnson
a48978a4bf Bug 666446, Part 6/10 - Change nsBulletFrame to utilize refresh driver-based animations for performance improvements. [r=roc] 2011-11-09 13:39:16 -08:00
Justin Lebar
86c0378be8 Back out bug 666446 due to Talos regression. 2011-11-02 20:11:01 -04:00
Scott Johnson
9cfbbc8b00 Bug 666446, Part 6/10 - Change nsBulletFrame to utilize refresh driver-based animations for performance improvements. [r=roc] 2011-11-01 11:06:53 -04:00
Timothy Nikkel
6744e4ecfa Bug 694213. Make various display items return bounds in the correct coordinate space. r=roc 2011-10-21 12:45:32 -05:00
Timothy Nikkel
79abab2e7b Backout 18f70ede04b0 (bug 694213). 2011-10-20 20:59:47 -05:00
Timothy Nikkel
332c11b9c9 Bug 694213. Make various display items return bounds in the correct coordinate space. r=roc 2011-10-20 12:44:28 -05:00
Timothy Nikkel
ab16fdd5c9 Backout 8db8c9ce92c5 (bug 694213). 2011-10-18 00:41:10 -05:00
Timothy Nikkel
5b00acba12 Bug 694213. Make various display items return bounds in the correct coordinate space. r=roc 2011-10-17 19:56:03 -05:00
Ehsan Akhgari
2a602a5685 Bug 690892 - Replace PR_TRUE/PR_FALSE with true/false on mozilla-central; rs=dbaron
Landing on a CLOSED TREE
2011-10-17 10:59:28 -04:00
Scott Johnson
f6b4eda7fc Backout cset 6cd4f2d8c2f9 from bug 666446 while we sort out regressions 2011-10-07 00:25:11 -07:00
Scott Johnson
90549abb9c Bug 666446, Part 6/18 - Change nsBulletFrame to utilize refresh driver-based animations for performance improvements. [r=roc] 2011-10-03 13:39:05 -07:00
Michael Wu
d8e503c38b Bug 675553 - Switch from PRBool to bool on a CLOSED TREE , r=bsmedberg,khuey,bz,cjones
--HG--
rename : tools/trace-malloc/bloatblame.c => tools/trace-malloc/bloatblame.cpp
2011-09-28 23:19:26 -07:00
Mats Palmgren
66c48bce55 Bug 663375 - When text color is darkened, darken text-decoration color too. r=dbaron 2011-08-09 17:14:36 +02:00
L. David Baron
c09bb2ecf4 Remove NS_STYLE_LIST_STYLE_OLD_* constants to fix computed list-style-type style resulting from type attribute on lists. (Bug 665857) r=bzbarsky 2011-06-29 14:39:21 -07:00
Robert O'Callahan
75ad705b3b Bug 641426. Part 3.5: Remove usage of nsMargin::TopLeft and nsMargin::IsZero. r=dbaron 2011-04-19 15:07:22 +12:00
Zack Weinberg
52c99aabb7 Bug 174055, part 6: eliminate pointless nsresult return values. 2011-04-07 21:18:43 -07:00
Zack Weinberg
624a6e3ce5 Bug 174055, part 5: prune unused and unimplemented methods. 2011-04-07 20:07:27 -07:00
Zack Weinberg
42ead75834 Bug 174055, part 4: mechanical fixups outside gfx. 2011-04-07 18:05:49 -07:00
Zack Weinberg
299386f14c Bug 174055, part 1: minimize inclusion of nsI(Thebes)FontMetrics.h. 2011-04-07 18:04:41 -07:00
Jan Küchler
5ef6bf26cf Bug 266236 part 3: Mechanical rename of nsIRenderingContext and nsThebesRenderingContext to nsRenderingContext. Mechanical substitution of nsRefPtr<nsRenderingContext> for nsCOMPtr<nsRenderingContext>.
--HG--
rename : gfx/src/nsThebesRenderingContext.cpp => gfx/src/nsRenderingContext.cpp
extra : rebase_source : 34884bfcafd885feaf73300bc7246cd192062a48
2011-04-07 18:04:40 -07:00
Alexander Surkov
8eec39795c Bug 629114 - crash on add comment link in review board [@ nsBulletFrame::GetListItemText ] [@ nsBulletFrame::GetListItemText(nsStyleList const&, nsString&) ], r=davidb, marcoz, sr=bz, a=blocking2.x+ 2011-03-28 22:59:54 +09:00
Robert O'Callahan
d886269e1d Bug 602757. Part 5: Change HasText to GetComponentAlphaBounds. r=tnikkel,sr=dbaron,a=blocking 2011-01-03 14:48:09 +13:00
timeless@mozdev.org
95d7ec83cd Bug 620252 RomanToText could use // FALLTHROUGH comments for 3 and 2, r+a=dbaron 2010-12-19 19:38:00 -08:00
Ehsan Akhgari
90e76bbb1f Bug 389321 - Part 3: Use a centralized algorithm for caret positioning; r=roc a=blocking-betaN+ 2010-08-31 14:54:44 -04:00
Matt Woodrow
47554e7736 Bug 594983. Look inside display sublists to determine whether there is text for the layer. r=roc,a=blocking 2010-10-11 13:58:20 +13:00
L. David Baron
40d60928c6 Fix miscellaneous reflow methods to use new overflow area APIs. (Bug 542595, patch 19) r=roc a2.0=blocking2.0:beta8 2010-10-06 21:25:46 -07:00
Alon Zakai
4606f548ac Bug 359608 - Animated GIFs are animated even when user navigates to another page.r=bholley,bz;sr=bz;a=blocker 2010-09-07 17:33:02 -07:00
Robert O'Callahan
812e6204ae Bug 584282. Use nsDisplayItem::ToReferenceFrame() instead of calling nsDisplayListBuilder::ToReferenceFrame, wherever possible. r=tnikkel,a=dbaron
--HG--
extra : rebase_source : 730ba8640cb37bd8484ff069b5d6fd46d9bc3e84
2010-08-13 22:01:58 +12:00
Robert O'Callahan
a581cd6197 Bug 584282. Add nsDisplayItem::mToReferenceFrame and initialize it in the constructor. r=tnikkel,a=dbaron
--HG--
extra : rebase_source : 496cbde7c495eb8872c3d0ffc0ca4c57c2a6a777
2010-08-13 22:01:13 +12:00
Daniel Holbert
5b754a5516 Bug 582004 part 2: Make imgIContainerObserver::FrameChanged take a const aDirtyRect argument. r=joe a=blocking 2010-08-13 21:09:48 -07:00
Michael Ventnor
8139bee929 Bug 564991. Part 3: Create unique nsDisplayItem types for every single display item. r=tnikkel 2010-07-16 09:07:49 +12:00
Saint Wesonga
e7a357dcaf Bug 562387 - Convert NS_NEWXPCOM/NS_DELETEXPCOM to new/delete. r=bsmedberg 2010-07-05 11:42:18 +02:00
Dão Gottwald
9b15b69a1b Backed out changeset 59ace8d80ce8 2010-07-04 22:01:13 +02:00
Saint Wesonga
8dd5da1024 Bug 562387 - Convert NS_NEWXPCOM/NS_DELETEXPCOM to new/delete. r=bsmedberg 2010-07-04 21:39:17 +02:00
Felipe Gomes
960464193b Bug 489127 - nodesFromRect required for better usability on mobile devices (part 1+2) [r=roc] 2010-04-07 20:31:26 -04:00
L. David Baron
b5cbbc06ce Use the appropriate color based on visitedness for the 'color' property. (Bug 147777) r=roc 2010-04-02 18:58:25 -07:00
L. David Baron
3a70c2f304 Ensure square list bullets are always square. (Bug 376690) r=roc 2010-02-18 12:26:54 -05:00
fantasai
1ffb0c06ef Bug 508473 part III: Pass destruction root to frame destruction methods r=bz sr=roc 2009-12-24 00:21:15 -05:00
Daniel Holbert
c94eb4c03e Bug 534171: Make sure to initialize local variable "success" in nsBulletFrame::AppendCounterText. r=dbaron 2009-12-12 22:27:31 -08:00
Olli Pettay
2f4c5ea761 Bug 487667 - Clone documents for printing, r=roc+jst+joe+dbaron
--HG--
extra : rebase_source : dbab242066ba97c0d7f34a2fb701a1c465f26ec4
2009-12-10 20:02:13 -08:00
Robert O'Callahan
d56dfa741e Bug 513082. Instead of passing aDirtyRect to nsDisplayItem::Paint, have nsDisplayList::OptimizeVisibility (renamed to ComputeVisibility) compute the intersection of the visible region with the bounds of each display item and store the result in the item's mVisibleRect. This lets us do less work to paint display items which have a small intersection with the visible region but a large intersection with the bounding-box of the visible region. r=dbaron
--HG--
extra : rebase_source : 76db4b87ef9e5a6e9de7677edc08c26e2cbc462e
2009-09-07 12:35:14 +12:00
Mats Palmgren
948203eb7d Replace PR_MIN/PR_MAX with NS_MIN/NS_MAX. b=512106 r=roc 2009-09-16 17:01:36 +02:00
Bobby Holley
2d5ec55945 Bug 435296 - Decode-On-Draw. r=joe,roc,bz,dolske,peterw sr=vlad 2009-09-12 16:44:18 -06:00
Zack Weinberg
17eb5a6efc Bug 497495 part 3: Add methods to every nsFrame subclass that expose the as-allocated identity of every frame object. Also some cleanups to the QueryFrame implementation. r=dbaron sr=roc 2009-09-12 17:49:24 +01:00
Jacek Caban
1728ef417e Bug 506034. Fixed loop on MinGW where wchar_t-char is unsigned. r=dbaron
--HG--
extra : rebase_source : def42dc23a878639a3251fdb681a9c138d16fa37
2009-08-05 14:39:05 +12:00
Joe Drew
6c441f55f7 Bug 753 - Remove nsIImage, gfxIImageFrame, and their implementations, and expose an equivalent api on imgIContainer. r=roc,josh,bz,longsonr,vlad,karlt,jimm,bsmedberg,mfinkle,peterw,peterv sr=vlad,roc
--HG--
rename : gfx/src/shared/gfxImageFrame.cpp => modules/libpr0n/src/imgFrame.cpp
rename : gfx/src/shared/gfxImageFrame.h => modules/libpr0n/src/imgFrame.h
2009-07-20 18:50:15 -07:00
Joe Drew
959ad4285f Bug 493240. r+sr=bzbarsky 2009-05-16 17:16:33 -04:00
Robert Longson
7506754d85 Bug 423756 - Support image-rendering attribute for html images and css backgrounds. r=joe,vlad sr=roc 2009-04-05 10:52:14 +01:00
Simon Montagu
209c6fcce0 Remove comment based on old version of CSS3 Lists spec. Comment-only change from bug 390440, rs=bz 2009-02-17 13:26:52 -08:00
Jeremy Lea
1800930122 Bug 448830. Make nsIntRect/nsIntMargin/nsIntSize/nsIntPoint different types from nsRect/nsMargin/nsSize/nsPoint different types for better compile-type unit checking. r+sr=roc
--HG--
extra : rebase_source : a331a9e49fbc5931f546919281fcca7f008ab615
2009-01-15 16:27:09 +13:00
Robert O'Callahan
0d380f02a0 Bug 458487 - 'Rework image snapping logic'. r=vlad+joedrew, sr=dbaron 2008-11-04 14:01:21 -08:00
Bernd
6777c42861 bug 258377, make border collapsed tables to listen for dynamic border style changes r/sr=bzbarsky 2008-10-26 11:11:34 +01:00
L. David Baron
9d7714304c Make sure DidSetStyleContext methods call the base class DidSetStyleContext, and change the signature to return void. (Bug 459649) r+sr=bzbarsky 2008-10-13 18:03:28 -04:00
Robert O'Callahan
f79290bb0e Bug 450930. Fire a DOM event when painting so that content and chrome can track what's being repainted. r=smaug,sr=dbaron 2008-09-18 21:47:21 +12:00
roc+@cs.cmu.edu
8dfb75f0cd Bug 420351. Don't let empty list-bullets make a line non-empty. r+sr=dbaron 2008-03-11 17:46:18 -07:00
roc+@cs.cmu.edu
b099594232 Backing out 420351 2008-03-11 03:44:32 -07:00
roc+@cs.cmu.edu
65180d9a75 Bug 420351. Empty bullets cannot make a line non-empty. r+sr=dbaron 2008-03-11 00:36:03 -07:00
reed@reedloden.com
70e372f1fb Bug 410114 - "Simplify nsTransform2D" [p=alfredkayser@gmail.com (Alfred Kayser) r+sr=roc a1.9=damons] 2008-02-26 01:42:36 -08:00
smontagu@smontagu.org
60180f6db8 Make Hebrew list numbering be ordered correctly. Bug 413928, r+sr=roc, blocking1.9=shrep 2008-02-13 00:21:59 -08:00
roc+@cs.cmu.edu
fb28ffc853 Bug 407889. Reduce dynamic memory allocations during event handling by having nested invocations of HitTest share a single buffer for reordering display items; this buffer is an nsAutoTArray so it's mostly stack-allocated. r+sr=mats 2008-01-03 18:08:29 -08:00
tglek@mozilla.com
fdf793303e Clean up prbool misuse in layout. bug 398312, r+sr+a=dbaron 2007-10-09 17:00:05 -07:00
roc+@cs.cmu.edu
bfd939088e Bug 96041. Compute precise glyph extents for high-quality text, and when requested. r=vlad,r+sr=dbaron 2007-09-23 19:19:14 -07:00
sharparrow1@yahoo.com
1eb555233b Bug 390740: Pass lang-group into GetMetricsFor more consistently (general patch). r+sr=roc, a=dbaron 2007-08-07 12:07:43 -07:00
jwalden@mit.edu
e3c4baccae Bug 348748 - Replace all instances of NS_STATIC_CAST and friends with C++ casts (and simultaneously bitrot nearly every patch in existence). r=bsmedberg on the script that did this. Tune in next time for Macro Wars: Episode II: Attack on the LL_* Macros. 2007-07-08 00:08:04 -07:00
bzbarsky@mit.edu
3cb4bc9240 Change the FrameNeedsReflow API to pass the dirty flags to be added directly tothe method, instead of setting them before calling the method. That way we canavoid reflowing the ancestor of a reflow root which is not itself dirty but hasdirty children. This also makes it harder to set dirty bits inconsistentlywith the FrameNeedsReflow call. Bug 378784, r+sr=dbaron, pending rbs' reviewon the mathml parts. 2007-05-06 12:16:51 -07:00
bzbarsky@mit.edu
2fd17c94d8 Rename nsIFrame::GetPresContext to nsIFrame::PresContext. Bug 376042, patch byTaras Glek <tglek@mozilla.com>, rs=roc. 2007-03-30 14:11:41 -07:00
hg@mozilla.com
465265d0d4 Free the (distributed) Lizard! Automatic merge from CVS: Module mozilla: tag HG_REPO_INITIAL_IMPORT at 22 Mar 2007 10:30 PDT, 2007-03-22 10:30:00 -07:00