Closed Bug 70704 Opened 24 years ago Closed 24 years ago

[XUL Syntax] Add XUL display types to CSS

Categories

(Core :: XUL, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla0.9

People

(Reporter: hyatt, Assigned: hyatt)

References

Details

(Keywords: helpwanted, Whiteboard: [XUL1.0])

Attachments

(5 files)

The basic XUL display types should be in CSS.
Looking for review, r/sr from attinasi, pierre, brendan. This is the first of several CSS patches that I'll be producing as visual properties from XUL move into CSS where they belong. All of the display types are properly prefaced with -moz-.
Status: NEW → ASSIGNED
I like where this is going. Do we want to #ifdef XUL all of the constants, keywords and properties as well as the code that uses it? It is unclear to me if this is a good idea or not: it would allow reduced memory footprint if XUL is not defined (admitedly small), but it would be, uh, messy. David, your thoughts?
My thought was that it wasn't worth cluttering up the code with #ifdefs in places where there's no real code/footprint impact, e.g., the definition of constants and keywords.
Depends on: 70753
Summary: Add XUL display types to CSS → [XUL Syntax] Add XUL display types to CSS
Whiteboard: [XUL1.0]
No longer depends on: 70753
Blocks: 70753
I guess I have to agree - clutter is bad and the memory required is tiny. [s]r=attinasi
mass-targetting to mozilla1.0, adding helpwanted keyword
Keywords: helpwanted
Target Milestone: --- → mozilla1.0
Another reason not to #ifdef the keywords and constants is that these UI elements have been proposed to XForms, and Ian is writing them up for CSS3, so they may not even stay XUL for long anyway. :) Anyone else on the cc list want to give me an r=?
Pierre's right, we shouldn't duplicate those keyword and property lists. I see another bug about fixing that, so on to the nit-picking! Select the following, notice the added (+) line of spaces -- I hate when that happens: @@ -5253,8 +5273,7 @@ // its default orientation is horizontal for hbox and vertical for vbox rv = NS_NewBoxFrame(aPresShell, &newFrame, PR_FALSE, nsnull, aTag != nsXULAtoms::vbox); - const nsStyleDisplay* display = (const nsStyleDisplay*) - aStyleContext->GetStyleData(eStyleStruct_Display); + // Boxes can scroll. if (IsScrollable(aPresContext, display)) { Here, the final line of the condition is indented one space too many: + else if ((!aXBLBaseTag && (display->mDisplay == NS_STYLE_DISPLAY_INLINE_GRID || + display->mDisplay == NS_STYLE_DISPLAY_GRID)) || + aTag == nsXULAtoms::grid || aTag == nsXULAtoms::tree) { Otherwise, looks good -- fix these if you share my anal-retentive appreciation for indentation, and rs=brendan@mozilla.org. /be
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Fixed.
Reopening. But wait, there's more! :)
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Status: REOPENED → ASSIGNED
Target Milestone: mozilla1.0 → mozilla0.9
Ok, this next patch adds all the remaining XUL widgets that merit their own display types. (I view all other XUL widgets as being one of these display types with some additional associated behavior.)
In the #2 content DLL patch, ignore all the stuff about scoped roots. That's a patch for another bug. Just look at the addition of the keywords. That's all that's relevant for this bug.
Well, in this case, diff -u produces some pretty darn unreadable diffs. Oh well. All I'm doing in the layout patch is moving the frame construction code down to the end of the function and making it key off display type rather than tag for those elements that now have display types. None of the code inside the ifs is changed. Ready for an r from pierre for the style system portions, and sr from brendan or attinasi.
The changes are fine but please rename the xul properties as "-moz-xul". r=pierre
sr=attinasi (assuming the changes to lazily initialize the mStyleRuleSupplier member of the SelectorMatchesData like in the other bug) Rock On, Dave!
Status: ASSIGNED → RESOLVED
Closed: 24 years ago24 years ago
Resolution: --- → FIXED
Fixed.
Component: XP Toolkit/Widgets: XUL → XUL
QA Contact: jrgmorrison → xptoolkit.widgets
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: