Looks like we can't reproduce the issue or there's a problem in the test case provided.
  1. #1
    Sencha Premium Member
    Join Date
    Jan 2012
    Posts
    10
    Vote Rating
    0
    nizhelya is on a distinguished road

      0  

    Default Legend and Background do not appear

    Legend and Background do not appear


    Generated by Architect 2 (on may 04 2012) code do not work (Legend and background ) (Changing legend position do not fix the problem - tested). The code :
    designer_code2.pngchart_from_Architect2.jpg

    If I edit it manually (in notepad etc., not in Architect 2) ( when I put the Legend and Gradient elements out of the InitComponent function) it works! This code is manually (notepad) corrected and working:
    edited_working_code2.jpgchart_edited.jpg




    Ext version tested:
    • Ext 4.0.7
    • Ext 4.1

    Browser versions tested against:
    • Firefox 11 (Linux)
    • Opera (latest)
    • Chrome (latest)

    Description:
    • Chart Legend and Background do not appear

    Steps to reproduce the problem:
    • Create the chart with the legend in Architect!! The same with background.

    The result that was expected:
    • Expected that the Legend will be visible. And the background feature will work.

    The result that occurs instead:
    • Legend is not visible. Background does not work too!!!

    Test Case: (see screenshots, there is a standart Architect generated code there(fig.1))

    Debugging already done:
    • hand rewriting works

    Possible fix:
    • Test the product.

    Additional CSS used:
    • default ext-all.css
    • additional CSS but it shall not affect the chart

    Operating System:
    • Linux Ubuntu
    Last edited by nizhelya; 4 May 2012 at 12:59 AM. Reason: to fit the requirements

  2. #2
    Sencha - Architect Dev Team Phil.Strong's Avatar
    Join Date
    Mar 2007
    Location
    Olney, MD
    Posts
    1,953
    Vote Rating
    65
    Phil.Strong is just really nice Phil.Strong is just really nice Phil.Strong is just really nice Phil.Strong is just really nice Phil.Strong is just really nice

      0  

    Default


    A little more information next time can help but let me tell you what I think is happening.

    1st are you using Designer 2 (old) or Architect 2 (new)?
    2nd it appears that the second screen shot your posting is the code generated by Architect?

    I also can't get this to work but charts are very fickle so if one thing is off it will refuse to render. The legend does work for me however in order to see it I must set a width and height on the chart. Width being greater than the left you have : 500
    Phil Strong
    @philstrong
    #SenchaArchitect
    Sencha Architect Development Team

  3. #3
    Sencha Premium Member
    Join Date
    Jan 2012
    Posts
    10
    Vote Rating
    0
    nizhelya is on a distinguished road

      0  

    Default


    Thanks, Phil!

    1) As I have the internet and the Architect updates automatically - so my product version is Sencha Architect Version 2.0.0. Build 412.

    2) I`ve corrected my post to make it more clear. The second code is handwritten in Notepad. More precisely, it is the edited code previously generated by Architect.

    3) I tried to play with coordinates ... No effect.

    This situation is really surprising, because the Architect is a commercial product, and at least the declared features are supposed to work ... IMHO

    Still waiting for help.

  4. #4
    Sencha Premium Member
    Join Date
    Mar 2013
    Posts
    2
    Vote Rating
    0
    dale.kort@str8lines.com is on a distinguished road

      0  

    Default Missing Chart Legend -- Issue Still Open

    Missing Chart Legend -- Issue Still Open


    Unfortunately found this thread after doing my own debugging and found the same results using the same results as before. It appears the previous post has been updated w/ the required information/syntax but I can provide additional details as well from my own use case if required.


    Architect Information
    Version: 2.2.2 Build: 991

    Release Channel: 2.2.2-stable


  5. #5
    Sencha - Architect Dev Team
    Join Date
    Jan 2009
    Location
    Frederick, Maryland
    Posts
    901
    Vote Rating
    32
    jminnick has a spectacular aura about jminnick has a spectacular aura about

      0  

    Default


    Quote Originally Posted by dale.kort@str8lines.com View Post
    Unfortunately found this thread after doing my own debugging and found the same results using the same results as before. It appears the previous post has been updated w/ the required information/syntax but I can provide additional details as well from my own use case if required.


    Architect Information
    Version: 2.2.2 Build: 991

    Release Channel: 2.2.2-stable

    If you wrap your chart with a panel; meaning the chart becomes an item of the panel it should render as you expect. This is a workaround until we can pinpoint the rendering issue.

    Like so (and i realize this is not the most elegant of solutions but if you're in a pinch it will get you by):

    Code:
    Ext.define('MyApp.view.MyPanel', {
        extend: 'Ext.panel.Panel',
    
    
        height: 591,
        width: 873,
        layout: {
            type: 'fit'
        },
        title: 'My Panel',
    
    
        initComponent: function() {
            var me = this;
    
    
            Ext.applyIf(me, {
                items: [
                    {
                        xtype: 'chart',
                        height: 472,
                        width: 683,
                        animate: true,
                        background: {
                            gradient: {
                                id: 'gradientId',
                                angle: 45,
                                stops: {
                                    0: {
                                        color: '#555'
                                    },
                                    100: {
                                        color: '#ddd'
                                    }
                                }
                            }
                        },
                        insetPadding: 20,
                        store: 'MyStore',
                        axes: [
                            {
                                type: 'Category',
                                fields: [
                                    'name'
                                ],
                                position: 'left',
                                title: 'Category Axis'
                            },
                            {
                                type: 'Numeric',
                                fields: [
                                    'data1',
                                    'data2',
                                    'data3',
                                    'data4',
                                    'data5'
                                ],
                                title: 'Numeric Axis',
                                position: 'bottom'
                            }
                        ],
                        series: [
                            {
                                type: 'bar',
                                label: {
                                    display: 'insideEnd',
                                    field: 'y',
                                    color: '#333',
                                    'text-anchor': 'middle'
                                },
                                axis: 'bottom',
                                xField: 'name',
                                yField: [
                                    'data1',
                                    'data2',
                                    'data3',
                                    'data4',
                                    'data5'
                                ]
                            }
                        ],
                        legend: {
    
    
                        }
                    }
                ]
            });
    
    
            me.callParent(arguments);
        }
    
    
    });
    Jason Minnick
    Sencha Architect Development Team

  6. #6
    Ext JS Premium Member
    Join Date
    Sep 2008
    Posts
    70
    Vote Rating
    0
    info@ferraresegroup.com is on a distinguished road

      0  

    Default Same problem

    Same problem


    Chart legend in Architect 2 don't' show.

    In Architect chart show well with Legend, in Chrome legend not show.

  7. #7
    Ext JS Premium Member
    Join Date
    Sep 2008
    Posts
    70
    Vote Rating
    0
    info@ferraresegroup.com is on a distinguished road

      0  

    Lightbulb Solve

    Solve


    Solved!
    In architect 2 when a chart is linked into panel or container, label don't show.
    If u move the chart inside the panel or container all work fine.

    It's another bug?
    Luca

  8. #8
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,413
    Vote Rating
    129
    aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold

      0  

    Default


    Yup, sounds like a bug in the framework either due to initialization or not pulling from the proto.
    Aaron Conran
    @aconran
    Sencha Architect Development Team