×

Discussion Board

Page 2 of 2 FirstFirst 12
Results 16 to 21 of 21
  1. #16
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: does Canvas support layering?

    I should add, I haven't tried this. I just knocked this code up as an example of how you could implement a UI Component model. You'd need to do quite a bit of work to build a complete implementation. (This is how LWUIT works.) For example, you'd need to implement a system whereby changes to the state of the component cause the container to repaint. Ideally, you'd want to change Container.paint(), so that it can handle a partial repaint, and only repaint Components in the affected area (rather than trying to repaint every component every time).

    In that code, I move the origin and set the clip region, so that in the component's paint method, the (0, 0) is in the top left corner of the component (no matter where it is on the screen). Remember that every component is being painted on the same Graphics object. Since this will be called for each component (in a loop), it's important to put everything back afterwards, so that the next component can be painted in the same way. Really, it should reset the colour, font, and so on, as well. Any change one component makes to the Graphics object should not affect later components.

    Graham.

  2. #17
    Regular Contributor
    Join Date
    Sep 2009
    Posts
    353

    Re: does Canvas support layering?

    Fine!, That explains it.
    LWUIT has some some good features but is it really as lightweight as its name suggests?
    I found some 3rd party libraries that support container-component architecture like MWT, Nextel, Synclast ... and another lightweight one called Kui, I am wondering whether to use these or just go along with the basics of the MIDP2.0 & CLDC1.1 api's.

  3. #18
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: does Canvas support layering?

    Quote Originally Posted by KevinBoyd View Post
    LWUIT has some some good features but is it really as lightweight as its name suggests?
    Hmmm... "lightweight" is a relative term. LWUIT is lighter-weight than Swing, heavier than LCDUI. I think it costs you about 400k of JAR, so it's pretty hefty in mobile terms. Not a great choice if you want to target devices with a JAR limit of 500k (or less!), but probably fine if you can install a JAR of 1Mb or greater.

    These are not something I use, as most of my work involves games, and so building very small, custom user interfaces. I can't give you much of a comparison.

    Graham.

  4. #19
    Nokia Developer Champion
    Join Date
    Feb 2009
    Location
    Noida, India
    Posts
    3,087

    Re: does Canvas support layering?

    LWUIT is not that BIG.... it does'nt add 400k of JAR load to any project, for a big commercial email client with 30 to 40 screen's and all type of transition effects, after obsfcation the extra load on jar due to LWUIT was hardly 100kb.
    You will get good amount of device supports, it works all MIDP 2.0/CLDC 1.1 devices and all components support TOUCH along with very good resource bundling/management & localization.


    thanks,
    ~Amitabh
    Follow me on my blog for Innovative Mobile Apps

  5. #20
    Regular Contributor
    Join Date
    Sep 2009
    Posts
    353

    Re: does Canvas support layering?

    @Amitabh
    @Graham

    I am looking at the best of both worlds, animation + components?
    I forgot another world "compactness"!
    From your experience what would you suggest?

    • Go with a third party library and save time on making your own framework?.
    • Do your own stuff as it wont take much time either.


    What 3rd party framework has the strengths for gaming and UI both?

  6. #21
    Nokia Developer Champion
    Join Date
    Feb 2009
    Location
    Noida, India
    Posts
    3,087

    Re: does Canvas support layering?

    @Amitabh
    @Graham

    I am looking at the best of both worlds, animation + components?
    I forgot another world "compactness"!
    From your experience what would you suggest?

    Go with a third party library and save time on making your own framework?.
    Do your own stuff as it wont take much time either.

    What 3rd party framework has the strengths for gaming and UI both?
    For application level animations and components -- LWUIT is good.
    I dont have much of games experiance to I cant say anything on that front.


    thanks,
    ~Amitabh
    Follow me on my blog for Innovative Mobile Apps

Similar Threads

  1. Clarifications/Information required about Technical Support case
    By mevasudeva in forum Feedback - Nokia Developer Services & Infrastructure
    Replies: 4
    Last Post: 2008-01-10, 13:39
  2. Technical Support Engineer, Mobile, London
    By mobile2004 in forum Symbian
    Replies: 0
    Last Post: 2004-11-05, 09:40
  3. Technical Support Engineer, Mobile, London
    By mobile2004 in forum Symbian
    Replies: 0
    Last Post: 2004-11-05, 09:38
  4. Technical Support Engineer, Mobile, London
    By mobile2004 in forum Symbian
    Replies: 0
    Last Post: 2004-11-05, 09:33
  5. Replies: 0
    Last Post: 2004-08-25, 11:42

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×