[CLOSED] Icons sometimes repeat

  1. #1

    [CLOSED] Icons sometimes repeat

    Hi,

    Most of your icons are fine as they are all assumed to be 16px by 16px. But I notice the flags typically end up repeating, because they are actually 12px in height.

    So I think you need to set the css property of background-repeat to no-repeat for these icons. Here's an example showing the effect with and without the css:

    <%@ Page Language="C#" %>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
        <title></title>
        <style type="text/css">
            .with-fix .x-label-icon { background-repeat:no-repeat; }
        </style>
    </head>
    <body>
        <ext:ResourceManager ID="ResourceManager1" runat="server" />
        <form id="HtmlForm" runat="server">
            <div>
                <ext:Label ID="Label1" Icon="FlagCn" runat="server" />
                <ext:Label ID="Label2" Icon="FlagEngland" runat="server" />
                <ext:Label ID="Label3" Icon="FlagGb" runat="server" />
                <ext:Label ID="Label4" Icon="FlagUs" runat="server" />
                <ext:Label ID="Label5" Icon="FlagIt" runat="server" />
            </div>
    
            <div class="with-fix">
                <ext:Label ID="Label6" Icon="FlagCn" runat="server" />
                <ext:Label ID="Label7" Icon="FlagEngland" runat="server" />
                <ext:Label ID="Label8" Icon="FlagGb" runat="server" />
                <ext:Label ID="Label9" Icon="FlagUs" runat="server" />
                <ext:Label ID="Label10" Icon="FlagIt" runat="server" />
            </div>
        </form>
    </body>
    </html>
    (Looking at your source code, I guess that would be in /extnet/core/init/End.js ?)
    Last edited by Daniil; Oct 06, 2011 at 3:27 PM. Reason: [CLOSED]
  2. #2
    Hi,

    We are investigating.

    Please clarify does it happens for <ext:Label> only?

    Quote Originally Posted by anup View Post
    (Looking at your source code, I guess that would be in /extnet/core/init/End.js ?)
    Yes, we add such fixes there.
  3. #3
    Good point... I saw it on a few other things like link button, menu items etc.

    Here's a few more items in the original test.

    There are quite a lot of permutations and combinations I have not tested...

    <%@ Page Language="C#" %>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
        <title></title>
        <style type="text/css">
            .with-fix .x-label-icon { background-repeat:no-repeat; }
        </style>
    </head>
    <body>
        <ext:ResourceManager ID="ResourceManager1" runat="server" />
        <form id="HtmlForm" runat="server">
            <div>
                <ext:Label ID="Label1" Icon="FlagCn" runat="server" />
                <ext:Label ID="Label2" Icon="FlagEngland" runat="server" />
                <ext:Label ID="Label3" Icon="FlagGb" runat="server" />
                <ext:Label ID="Label4" Icon="FlagUs" runat="server" />
                <ext:Label ID="Label5" Icon="FlagIt" runat="server" />
                <ext:LinkButton Icon="FlagGb" Text="Link Button" runat="server" />
                <ext:Button Icon="FlagGb" Text="Button" runat="server" />
            </div>
    
            <ext:Panel Icon="FlagIt" runat="server" Html="Panel" Title="Ext Panel">
                <TopBar>
                    <ext:Toolbar runat="server">
                        <Items>
                            <ext:Button Icon="FlagAd" Text="Button with Menu" runat="server">
                                <Menu>
                                    <ext:Menu runat="server" Text="Menu">
                                        <Items>
                                            <ext:MenuItem Icon="FlagRu" Text="Menu Item" runat="server" />
                                            <ext:MenuItem Icon="FlagGb" Text="Menu Item" runat="server" />
                                        </Items>
                                    </ext:Menu>
                                </Menu>
                            </ext:Button>
                            <ext:SplitButton Icon="FlagFr" Text="Split button" runat="server">
                                <Menu>
                                    <ext:Menu ID="Menu1" runat="server" Text="Menu">
                                        <Items>
                                            <ext:MenuItem ID="MenuItem1" Icon="FlagRu" Text="Menu Item" runat="server" />
                                            <ext:MenuItem ID="MenuItem2" Icon="FlagGb" Text="Menu Item" runat="server" />
                                        </Items>
                                    </ext:Menu>
                                </Menu>
                            </ext:SplitButton>
                        </Items>
                    </ext:Toolbar>
                </TopBar>
            </ext:Panel>
    
            <div class="with-fix">
                <ext:Label ID="Label6" Icon="FlagCn" runat="server" />
                <ext:Label ID="Label7" Icon="FlagEngland" runat="server" />
                <ext:Label ID="Label8" Icon="FlagGb" runat="server" />
                <ext:Label ID="Label9" Icon="FlagUs" runat="server" />
                <ext:Label ID="Label10" Icon="FlagIt" runat="server" />
            </div>
        </form>
    </body>
    </html>
  4. #4
    Thanks a lot for the sample.

    We are considering to fix it in SVN. We will back with an update.
  5. #5
    The fix has been added to SVN (.registerIcon() of Ext.net.ResourceManager), revision #3729.

    Thanks for the report.
  6. #6
    Sorry it has taken so long to follow up - got latest and confirmed this is resolved. Many thanks.
  7. #7
    No problem.

    Thanks for the feedback!

Similar Threads

  1. [CLOSED] Some icons repeat - was fixed in 1.0
    By anup in forum 2.x Legacy Premium Help
    Replies: 2
    Last Post: May 27, 2012, 10:27 PM
  2. [CLOSED] icons
    By rnachman in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Feb 16, 2012, 6:46 PM
  3. [CLOSED] Duplicated icons
    By Vladimir in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Nov 29, 2010, 5:37 PM
  4. Replies: 0
    Last Post: Apr 03, 2009, 5:47 AM
  5. [CLOSED] Loop through icons?
    By Jurke in forum 1.x Legacy Premium Help
    Replies: 9
    Last Post: Dec 11, 2008, 12:05 PM

Posting Permissions