1. #1
    Sencha User
    Join Date
    Nov 2011
    Posts
    19
    Answers
    1
    Vote Rating
    0
    jweymarn is on a distinguished road

      0  

    Question Answered: Graph rendering only halfway

    Answered: Graph rendering only halfway


    Hey gurus!

    Noob with a question!

    Im having a problem with rendering as seen in attached image.

    extjsQ.jpg

    I have a vieport, containing a border layout. When I click elements in the west layout element I want to change what is seen in the center area. The center layout has a div with
    id = content
    Depending on what is clicked I trigger functions that create a Panel containing the stuff I want. I tell the panels where to render by
    renderTo: 'content'
    This is working wonderfully except that it draws only half. If I re-size the browser or drag a border inside any element it is re-rendered to show the whole element. No difference what browser is used.

    I have tried (among others):
    animate();
    doAutoRender();
    doComponentLayout();
    doLayout();

    Any hints?

  2. Why are you using renderTo?

    You center region should be a Container using fit layout. When you click on something in the west region, you add a chart to the center region's container.

  3. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,672
    Answers
    3354
    Vote Rating
    748
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Why are you using renderTo?

    You center region should be a Container using fit layout. When you click on something in the west region, you add a chart to the center region's container.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  4. #3
    Sencha User
    Join Date
    Nov 2011
    Posts
    19
    Answers
    1
    Vote Rating
    0
    jweymarn is on a distinguished road

      0  

    Default


    Thanks for you reply.

    I´m using renderTo because it sounds like the most logical command to use and many examples also use it...

    you add a chart to the center region's container.
    Could you give a hint towards how i add the chart to the container?
    Something like have all my charts inside it and hide all but the one i want to show? Using graph.show() and graph.hide()?

  5. #4
    Sencha User
    Join Date
    Nov 2011
    Posts
    19
    Answers
    1
    Vote Rating
    0
    jweymarn is on a distinguished road

      0  

    Default


    Figured it out and now it´s working as it should.

    If someone else ends up here with a similar problem this is my setup:
    1. Init global variables ie. historyChart, radarChart, table1
    2. Use these global variables for my graphs. No renderTo at all.
    Code:
    historyChart = new Ext.chart.Chart({
    ...
    3. Draw the layout and in there add my graphs as items:
    Code:
    items:[historyChart, radarChart, table1]
    4. Show and hide these with
    Code:
    historyChart.hide();
    radarChart.show();

Thread Participants: 1

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar