1. #1
    Sencha User
    Join Date
    Feb 2012
    Posts
    37
    Vote Rating
    0
    sanova is on a distinguished road

      0  

    Default Answered: Method resize in image field

    Answered: Method resize in image field


    Hi,
    i'm using extjs 4.1.
    Is there some option to make resize of an image into field (xtype: image) inside a container having fixed size like this:

    PHP Code:
    {
    xtype'container',
    width300,
    height300,
    items: [
       {
           
    xtype'image',
           
    width'100%',
           
    height'100%',
           
    mode'' //  <-- here some mode to resize image to container parent size
           
    src'path/to/image/image.png',
           
    styleHtmlContenttrue,
           
    flex1
       
    }
    ]

    This only for the case i have a big image with big resolution and so to adapt it to container size.

    Thanks in advanced.

  2. Code:
    {
        xtype: 'container',
        width: 300,
        height: 300,
        layout: 'fit',
        items: [{
            xtype: 'image',
            src: 'path/to/image/image.png'
        }]
    }

  3. #2
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,823
    Answers
    453
    Vote Rating
    608
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      1  

    Default


    Code:
    {
        xtype: 'container',
        width: 300,
        height: 300,
        layout: 'fit',
        items: [{
            xtype: 'image',
            src: 'path/to/image/image.png'
        }]
    }
    Evan Trimboli
    Sencha Developer
    Twitter - @evantrimboli
    Don't be afraid of the source code!

  4. #3
    Sencha User
    Join Date
    Feb 2012
    Posts
    37
    Vote Rating
    0
    sanova is on a distinguished road

      0  

    Default


    Thank you Evant, it seems it works very good.

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi