Mozilla

NAVIGATION
CATEGORIES
REFERRENCE
LINKS
  • Web Forms 2 new elements: C++ or XBL?

    6 answers - 1101 bytes - related search similar search Add To My Delicious Add To My Stumble Upon Add To My Google Mark Add To My Facebook Add To My Digg Add To My Reddit

    Gentlemen, I intend to do a large part of the work to implement Web
    Forms 2.0 for Mozilla, but I need a fundamental question answered.
    The general consensus I received is that new widgets whenever possible
    should be implemented in XBL. However, Boris Zbarsky has pointed out
    this is infeasible because XBL bindings currently cannot apply 100% of
    the time (he cited as an example how the display:none style property
    breaks bindings).
    I am perfectly willing to write new widgets in C++ or in XBL, but I need
    a solid decision from the content module owner and peers on this.
    Should I write these controls in C++, XBL or some other format?
    If the route should be XBL-based controls, how can we unconditionally
    guarantee the bindings will apply?
    I have also considered XTF-based implementations, but because Web Forms
    2 is theoretically in the same namespace as XHTML (and lives in harmony
    with HTML), this option appears closed to me.
    Alex Vincent
    dev-tech-dom mailing list
    dev-tech-dom (AT) lists (DOT) mozilla.org
  • No.1 | | 1566 bytes | |

    I would not recommend using XBL to implement properties on the elements.
    reason is the one bz brought up, that in some circumstances the
    binding doesn't get added.

    Another problem is if someone adds a binding of their own to style the
    control you'll loose all properties defined in your binding, which is
    not expected behaviour.

    You can probably use XBL to style the control though.

    / Jonas

    Alex Vincent wrote:
    Gentlemen, I intend to do a large part of the work to implement Web
    Forms 2.0 for Mozilla, but I need a fundamental question answered.

    The general consensus I received is that new widgets whenever possible
    should be implemented in XBL. However, Boris Zbarsky has pointed out
    this is infeasible because XBL bindings currently cannot apply 100% of
    the time (he cited as an example how the display:none style property
    breaks bindings).

    I am perfectly willing to write new widgets in C++ or in XBL, but I need
    a solid decision from the content module owner and peers on this. Should
    I write these controls in C++, XBL or some other format?

    If the route should be XBL-based controls, how can we unconditionally
    guarantee the bindings will apply?

    I have also considered XTF-based implementations, but because Web Forms
    2 is theoretically in the same namespace as XHTML (and lives in harmony
    with HTML), this option appears closed to me.

    Alex Vincent

    dev-tech-dom mailing list
    dev-tech-dom (AT) lists (DOT) mozilla.org
  • No.2 | | 315 bytes | |

    Jonas Sicking wrote:
    You can probably use XBL to style the control though.

    C++ for the implementation/handlers, and XBL for the appearance I
    don't see how to do that. Could you give me a hint?

    Alex

    dev-tech-dom mailing list
    dev-tech-dom (AT) lists (DOT) mozilla.org
  • No.3 | | 483 bytes | |

    Alex Vincent wrote:
    Jonas Sicking wrote:
    >You can probably use XBL to style the control though.


    C++ for the implementation/handlers, and XBL for the appearance I
    don't see how to do that. Could you give me a hint?

    Add C++ code that adds properties. Then add CSS rules to html.css that
    adds bindings with appearance.

    / Jonas

    dev-tech-dom mailing list
    dev-tech-dom (AT) lists (DOT) mozilla.org
  • No.4 | | 583 bytes | |

    Alex Vincent wrote:
    Jonas Sicking wrote:
    >You can probably use XBL to style the control though.


    C++ for the implementation/handlers, and XBL for the appearance I
    don't see how to do that. Could you give me a hint?

    Alex

    Just look at how XForms does that ;)
    Though it is using XTF+XBL. XTF for most of the logic, XBL for context
    dependent presentation (i.e. same XTF code in XHTML and XUL, but
    different bindings)
    -S

    dev-tech-dom mailing list
    dev-tech-dom (AT) lists (DOT) mozilla.org
  • No.5 | | 870 bytes | |

    smaug wrote:
    Alex Vincent wrote:
    >Jonas Sicking wrote:

    You can probably use XBL to style the control though.
    >>

    >C++ for the implementation/handlers, and XBL for the appearance I
    >don't see how to do that. Could you give me a hint?
    >>

    >Alex


    Just look at how XForms does that ;)
    Though it is using XTF+XBL. XTF for most of the logic, XBL for context
    dependent presentation (i.e. same XTF code in XHTML and XUL, but
    different bindings)
    -S

    *sigh* As I have already explained, I cannot use XTF. WF2 code largely
    lives in the same environment as HTML, whereas XTF is for new XML
    namespaces.

    dev-tech-dom mailing list
    dev-tech-dom (AT) lists (DOT) mozilla.org
  • No.6 | | 400 bytes | |

    Alex Vincent wrote:
    >Just look at how XForms does that ;)
    >Though it is using XTF+XBL.
    >

    *sigh* As I have already explained, I cannot use XTF.

    Right. So you would use C++ for the implementation, instead of XTF, and XBL for
    the presentation.
    -Boris

    dev-tech-dom mailing list
    dev-tech-dom (AT) lists (DOT) mozilla.org

Re: Web Forms 2 new elements: C++ or XBL?


max 4000 letters.
Your nickname that display:
In order to stop the spam: 9 + 8 =
QUESTION ON "Mozilla"

EMSDN.COM