UINavbaritem:initWithTitle:image doesnt work, bug? Image link inside

I have the following code
UIImage *image = [[UIImage imageNamed:@"test.png"] retain];
self.tabBarItem = [[UITabBarItem alloc] initWithTitle:@"Test" image:image tag:0];
But the image doesnt show up, only a square shows up in place of it any ideas?
link to see:
http://img171.imageshack.us/img171/2052/picture1gu6.png

From the docs for initWithTitle:image:tag:
The images displayed on the tab bar are derived from this image. If this image is too large to fit on the tab bar, it is scaled to fit. The size of an tab bar image is typically 30 x 30 points. The alpha values in the source image are used to create the unselected and selected images—opaque values are ignored.
I'd guess that the image you are using is all opaque. Look at the tab bar images with the TheElements example app. You will see there is no real color, just alpha.

Similar Messages

  • Image should work as hyper link in smartform

    Hi,
    I am able to convert smartform with images in to HTML format and able to send as e-mail using the program similar to SF_XSF_DEMO_MAIL.
    As soon as the user receives e-mail, he should able to click on images and should redirect to other webpage. (Image should work like hyper link).
    Can you please suggest how to work on this issue ?
    Thank you very much.
    Regards
    Badari

    Using smart form we can not send image as hyper link. This functionality is not available using smartform.
    Instead of using smart form written the HTML Code and used the following function module  'SO_NEW_DOCUMENT_ATT_SEND_API1' and works fine for me.
    wa_objtxt-line ='</body>'.
      APPEND wa_objtxt TO t_objtxt.
      wa_objtxt-line = '</html>'.
      APPEND wa_objtxt TO t_objtxt.
      HTML close
      wa_objtxt-line = '</body> </html> '.
      APPEND wa_objtxt TO t_objtxt.
    Document data
      DESCRIBE TABLE t_objtxt      LINES w_tab_lines.
      READ     TABLE t_objtxt      INTO wa_objtxt INDEX w_tab_lines.
      wa_docdata-doc_size =
          ( w_tab_lines - 1 ) * 255 + STRLEN( wa_objtxt ).
    Packing data
      CLEAR wa_objpack-transf_bin.
      wa_objpack-head_start = 1.
      wa_objpack-head_num   = 0.
      wa_objpack-body_start = 1.
      wa_objpack-body_num   = w_tab_lines.
      we will pass the HTML, since we have created the message
      body in the HTML
      wa_objpack-doc_type   = 'HTML'.
      APPEND wa_objpack TO t_objpack.
    *ENDFORM.                    " CREATE_TITLE_DESC_BODY
    *&      Form  fill_receivers
          Filling up the Receivers
    *FORM fill_receivers .
      wa_reclist-receiver = I_email. "p_email.
      wa_reclist-rec_type = 'U'.
      APPEND wa_reclist TO t_reclist.
      CLEAR  wa_reclist.
    *ENDFORM.                    " fill_receivers
    *&      Form  send_message
          Sending Mail
    *FORM send_message .
    Send Message to external Internet ID
      CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
        EXPORTING
          document_data              = wa_docdata
          put_in_outbox              = 'X'
          commit_work                = 'X'     "used from rel.6.10
        TABLES
          packing_list               = t_objpack
          object_header              = t_objhead
          contents_txt               = t_objtxt
          receivers                  = t_reclist
        EXCEPTIONS
          too_many_receivers         = 1
          document_not_sent          = 2
          document_type_not_exist    = 3
          operation_no_authorization = 4
          parameter_error            = 5
          x_error                    = 6
          enqueue_error              = 7
          OTHERS                     = 8.
      IF sy-subrc NE 0.
        E_STATUS = 'Sending Failed'.
      ELSE.
        E_STATUS = 'Sending Successful'.
      ENDIF.
    Edited by: Badari Narayana1 on Oct 6, 2009 10:09 PM
    Edited by: Badari Narayana1 on Oct 6, 2009 10:09 PM
    Edited by: Badari Narayana1 on Oct 6, 2009 10:10 PM

  • Assigned ringtones with image doesnt work together...

    hello, could someone help on my new nokia 5800, while using the image (stored n tranferred frm pc by reducing the required size) I cant hear the spl ringtone assigned to the same contact. Though if i use nokia inbuilt images (came with the set) or dont use any image, I can hear the spl ringtone assigned to the contact as well as the image.
    cheers!!
    lalit

    Problem solved. I got my 5800xm six days ago and just figured the problem with my ring tones. Its very easy just go to your contacts and set the numbers as they appear when someone calls you I am from Trinidad but in my contacts I had the numbers starting with *31# and then the persons number because in Trinidad with bmobile if you block your phone's number  from the settings you can just use *31# in front the persons number & it will show. My wife just called me and the ringtone played so I wondered how come so I checked the number & notice it was the same work # she called me from yesterday and I saved it not having time to put *31# in front of it .In my contacts I had the number but with *31# in front of it for eg I had in my contacts *31#7566766 the # I save was the same but it appeared on my phone as 8687566766 and thats how I solved the problem It's just your Country code in front the numbers in the contacts so now I put *31#8687566766 and it works with no problems (In Trinidad our country code is 868). Or if not just put the numbers you see when someone calls you its that easy.

  • Printing mirror image doesnt work

    Hey OT,
    Tried your method and worked up to a point, when I try to print the flipped image it opens a new preview screen with the original unflipped image and thats the one that prints. Anyone any more ideas? Or am I doing something wrong?
    Thanks!

    You don't have to be flippant unless you don't want anyone to offer any help at all. The excuuuuuuuse me part was juvenile and you should edit it out.
    You started a thread and it makes sense to post to that thread in reply to what you were told to do to advise the original person that it didn't work.

  • Compare with unedited image doesnt work

    hi
    i started my first project in lightroom, and i use to change the look of my images in the development section every day again (a bit here, a bit there).
    when i press before/after, LR5 only shows the version i did yesterday and the one from now, today, how can i see the unedited version of the image, which i imported last week?
    thanks
    peter

    Here is one way to do it:
    Activate Before/After, then on the Before/After toolbar options below the pair of images:
    Click the Copy After to Before button (the arrow pointing from the right-side to the left) so that both Before and After are your latest adjustments.
    Click Reset at the bottom right in Develop to reset the After view.
    Click Swap Before/After (the double-arrows pointing left-to-right and right-to-left) to put the Reset one at the left and the After one with your current settings.
    This will leave a trail in history so you may not want to do it this way.
    You can also, in place of doing the Reset, click on one of the history steps, then swap Before and After.  This will compare the current settings to that older history step.

  • Reader 9 - print as image - doesnt work

    In 9.1 with some documents with unicode (czech) signs, these are wrong printed even if I have "print as image". The old 8.1 prints the same docs well. Can someone help? I do not want to return to older version. Having xp sp3.

    B.U.M.P. to the top ... still wondering!?!?

  • Rollover images stop working when image lies on top

    Hello,
    I am trying to place a PNG image over my menu bar. This is a swoosh which overlaps certain areas on the menu bar, the swoosh is a PNG file with no BG. It seems that the swoosh retaining box, stops the rollover buttons from working. They work up to the point in which the swoosh box starts.
    Am i missing something really simple, or is it a common fault.
    Go easy on me as it is my first post
    Thank you
    Will

    The menu bar in blue is positioned behind the blue and yellow swoosh. The rollove effect works when the curser is on the text but as you move down, the rollover effect stops, its at the position where the swoosh retaining box starts that the rollover effect stops working. Its to do with the layers im sure, i just thought seeing as the swoosh pixels dont interfere that obejct behind should be selectable.
    Does this help?

  • MPLS doesnt work with edundant link

    The P router is connected with PE via 2 link. One is working as primary, and other one working as secondry. When i shut down the primary link, the MPLS traffic works well. But, when i bring the primary link up and shut down the secondry link, MPLS traffic doesn't work. Whereas, there is no problem in the normal IP traffic. But, when i shut and no shut the primary interface, MPLS traffic starts working normal. What could be the problem? Attached is the configuration of PE device for your refrence? By the way, P device is from Huawei. I really need to solve this problem as soon as possible. Please respond.
    interface GigabitEthernet3/4
    description __________________________
    ip address 72.178.x.x.255.255.252
    ip ospf message-digest-key 1xxx
    ip ospf cost 100
    speed nonegotiate
    mpls label protocol ldp
    tag-switching ip
    no cdp enable
    end
    interface GigabitEthernet3/3
    description _______________________
    ip address 52.178.x.x.255.255.252
    ip ospf message-digest-key xxx
    speed nonegotiate
    mpls label protocol ldp
    tag-switching ip
    no cdp enable

    Hi,
    In fact it should work except of maybe a transient connectivity break because of a race condition. OSPF and LDP will start sending hellos and setting up adjacencies and LDP session, respectively.
    Once OSPF is converged it will start using the new/reenabled link. OSPF routing decision does not take LDP availability into account. So when LDP is not ready yet, but OSPF decides to send all traffic over the primary link, there are no labels yet (show mpls forwarding-table, search for "untagged"). Thus connectivity for VPN traffic is broken.
    One way of overcoming this is to use targeted LDP:
    R(config)# mpls ldp neighbor x.x.x.x targeted ldp
    This means the LDP session is kept even if the interface is down, as long as x.x.x.x has IP connectivity.
    Now all this said, it should recover without manual intervention. Your config looks fine to me. Have you checked, what the underlying problem is?
    show mpls ldp discovery ! are LDP hellos sent and received after link recovery?
    show mpls ldp neighbor ! is LDP session reestablished?
    show mpls forwarding-table ! are labels entered into LFIB after link recovery?
    Targeted LDP might still solve your problem, because you would not loose the LDP session.
    Hope this helps! Please rate all posts.
    Regards, Martin

  • Float images in photoshop cs4 - edit preferences untick open doc as tab doesnt work

    Hi, i have read about floating all images in windows on the forums and i have tried unticking the open documents as tabs in the edit preferences - interface section and it doesnt work, my hand is really starting to hurt, i dont know why this isnt working ?

    If you drag the files to the margins (e.g., near the menu bar) of Photoshop CS4 (11.0.2), and not to the workspace, they will actually open as windows.
    It'll actually do the expected thing in CS5 (i.e., open as Window) even if you drag the file to the workspace - in other words they finally fixed that bug.
    Kind of a shame Adobe doesn't think blatantly wrong stuff like the "drag to workspace always opens a tabbed view" bug is important enough to fix in maintenance releases for older products.
    -Noel

  • Hi, firstly my ipod touch is working fine in itunes. i reformated my computer so i lost all my old drivers ect ect, so now my ipod shows up as an image device. i have reinstalled itunes several times and installed apple mobile device but still doesnt work

    hi, firstly my ipod touch is working fine in itunes. i reformated my computer so i lost all my old drivers ect ect, so now my ipod shows up as an image device. i have reinstalled itunes several times and installed apple mobile device but still doesnt work, i have also searched for the usbappl or whatever it is and i cant find it, i have usbappl .dll but no .sys or .inf please help

    All it is supposed to show up as in Windows is an image device.
    If it's working fine in iTunes, what is the issue?

  • Can't get rollover images to work as links [was: I have a question if someone could answer?]

    I have fixed my page so I can preview it and everything is working fine but now I cant get my rollover images to work as links.  When I go to put in the link like normal the rollover behavior stops working and it is just the original image.  Any way for me to turn it into a link but still keep the rollover image change?
    [Subject line edited by moderator. Please use more meaningful subject lines in future.]

    Can you provide a link to your website so we can see what you're seeing?
    Without one, you're asking for an answer based on guesswork.

  • Image format not working automatically when linking to Frame files

    I have a project in RoboHelp that has linked Frame files. I've fiddled with the settings until I can update and publish without having to make any changes to most of the RoboHelp project's files. However, there is a problem with the images. My group's standard is to center the images. All the settings are set for that. However, they are left-aligned in the generated CHM file, unless I double click one image in each topic to open the Image Properties box, make NO changes, and click OK to close the Image Properties box. I've checked the HTML code before and after doing this, and there is no change, but then all the images in each topic that I did this to will appear centered in the generated CHM file. Since I have about 100+ graphics in this project, it would be nice if I could get the settings to take effect without having to go through this exercise. Anyone know how to make RoboHelp recognize the settings without having to touch an image in each topic in the project?

    Sure, here is the HTML code for one of the images. All the images I've checked, working or not, have identical code except of course the reference to the image file. 
    <div style="text-align: center;">
    <img alt="SSI_User_Manual_Chapter0200004.png" id="image4" src="SSI_User_Manual_Chapter0200004.png"
       style="margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px;"
       width="494" height="331" border="0" />
    </div>
    I searched the CSS and do not find duplicate entries. Perhaps the <div style="text-align: center;"> is a problem? I believe that RH is adding that because the graphics were centered in FrameMaker. It is not in my CSS.

  • BUG - Drag and drop an image, only working at the 2nd try

    I use the last version of JDeveloper : 11g R1 : 11.1.1.2.0
    I try to drag and drop an image in a facet of a panelsplitter.
    Once the page is loaded, the first time I try to drag the image, it does not work : the image does not follow the mouse.
    When I try to drag the image again, then it works : the image follow the mouse
    So I don't think it's related to the destination/target.
    I feel it's so simple, since it just requires to add <af:componentDragSource/> inside <af:image/>
    that if it does not work, it can only be a bug in the functionality offered by ADF ...
    Or maybe there is something wrong with the generation of the page ?
    I get this message in blue in the "running log of WebLogic" :
    <FormRenderer><setupEncodingContext> Multiple forms detected on viewId: /myPage.jspx. Rich client currently has some limitations in dealing with multiple forms.
    Please note that I use jsp:include inside f:subview to include fragments (.jsff) so that the source and the destination are not in the same file, the source in a .jsff while the destination is on the main .jspx
    The code related to the drag and drop :
    <af:form id="form">
    <af:panelSplitter orientation="vertical" splitterPosition="70" id="psHeader" clientComponent="true">
    <af:panelAccordion id="paPref" discloseNone="true" styleClass="fullSize">
    <af:showDetailItem id="sdiTemp" text="Templates">
    <af:panelBox>
    <af:panelGroupLayout id="pglTemp" layout="scroll">
    <af:panelList id="plTemp" rows="2">
    <af:image id="imTemp2up" source="/images/anImage.jpg" inlineStyle="" shortDesc="...">
    <af:componentDragSource/>
    </af:image>
    <f:facet name="second">
    <af:dropTarget dropListener="#{dropHandler.handleComponentMove}" actions="MOVE">
    <af:dataFlavor flavorClass="javax.faces.component.UIComponent"/>
    </af:dropTarget>
    Any idea ?
    Thanks in advance,
    JP

    Hi,
    no bug that I can detect here as it works for me with the same setup. How likely is it that the image is too small so that you don't grab it probably the first time?
    Frank

  • Moving images doesnt update links in topics

    RH8 HTML.
    I moved some images around, renamed the folder containing them (all in RH). But the topics that use those images still hold the old link, and wont update to where the folder where the iamges are stored so all the links are dead. Is there a way to force a re-scan or something to make the topics look for the new location of the images, or do I have to change the paths manually in each topic where the links are broken?
    I would have thought that when moving images in RH it would update paths in topics where those images are used so that it wouldnt have to be done manually.

    Obviously those images were showing in Project Manager before you started moving the topics around, RH has always reworked the path reliably. It does not if you move them in Windows Explorer but you say that is not what you did.
    If you right click an image and select Properties,  you can see Used In. Is that blank?
    Create a test project and create some folders and topics with images. Move things around and check it all works as it should.
    Post back how that goes.
    See www.grainge.org for RoboHelp and Authoring tips

  • Dynamic imaging in jsp doesnt work

              Hi,
              The following piece of code works in tomcat but does not work in weblogic. can
              anybody please help me with this.
              <%@ page contentType="image/jpeg" import="java.awt.*,java.awt.image.*,com.sun.image.codec.jpeg.*,java.util.*"%>
              <%
              // Create image
              int width=200, height=200;
              BufferedImage image = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB);
              // Get drawing context
              Graphics g = image.getGraphics();
              // Fill background
              g.setColor(Color.white);
              g.fillRect(0, 0, width, height);
              // Create random polygon
              Polygon poly = new Polygon();
              Random random = new Random();
              for (int i=0; i < 5; i++) {
              poly.addPoint(random.nextInt(width),
              random.nextInt(height));
              // Fill polygon
              g.setColor(Color.cyan);
              g.fillPolygon(poly);
              // Dispose context
              g.dispose();
              // Send back image
              ServletOutputStream sos = response.getOutputStream();
              JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(sos);
              encoder.encode(image);
              %>
              Thanx in advance.
              regards,
              Subramaniam
              

              Thanx a lot.Just read your solution again. Didnt get it the first time .Its pretty
              interesting.I think i will opt for the servlets solution.
              Dimitri Rakitine <[email protected]> wrote:
              >I thought I did. This version works (on 6.1 at least) :
              >
              >----------
              ><%@ page contentType="image/jpeg" import="java.awt.*,java.awt.image.*,com.sun.image.codec.jpeg.*,java.util.*"%><%
              >
              >// Create image
              >int width=200, height=200;
              >BufferedImage image = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB);
              >
              >// Get drawing context
              >Graphics g = image.getGraphics();
              >
              >// Fill background
              >g.setColor(Color.white);
              >g.fillRect(0, 0, width, height);
              >
              >// Create random polygon
              >Polygon poly = new Polygon();
              >Random random = new Random();
              >for (int i=0; i < 5; i++) {
              > poly.addPoint(random.nextInt(width),
              > random.nextInt(height));
              >}
              >
              >// Fill polygon
              >g.setColor(Color.cyan);
              >g.fillPolygon(poly);
              >
              >// Dispose context
              >g.dispose();
              >
              >// Send back image
              >ServletOutputStream sos = response.getOutputStream();
              >JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(sos);
              >encoder.encode(image);
              >%>
              >----------
              >
              >Subramaniam <[email protected]> wrote:
              >
              >> Hi,
              >
              >> There is out.println("\n")'s in the java file generated by weblogic.
              >There is
              >> out.write("\n")'s in the java file generated by tomcat. So does that
              >make a difference
              >> ?
              >
              >> You told me to make a change in the jsp - could you be more specific
              >as to what
              >> change needs to be made(if i dont want to use a servlet).
              >
              >> Thanx in advance,
              >
              >> Subramaniam
              >
              >> Dimitri Rakitine <[email protected]> wrote:
              >>>Look at the generated .java file - WebLogic's JSP compiler adds
              >>>'out.println("\n")'s at the beginning. Try to change your JSP (or,
              >>>even better, use servlet to generate images) :
              >>>
              >>><%@ page contentType="image/jpeg" import="java.awt.*,java.awt.image.*,com.sun.image.codec.jpeg.*,java.util.*"%><%
              >>>
              >>>// Create image
              >>>int width=200, height=200;
              >>>BufferedImage image = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB);
              >>>
              >>>// Get drawing context
              >>>Graphics g = image.getGraphics();
              >>>
              >>>// Fill background
              >>>g.setColor(Color.white);
              >>>g.fillRect(0, 0, width, height);
              >>>
              >>>// Create random polygon
              >>>Polygon poly = new Polygon();
              >>>Random random = new Random();
              >>>for (int i=0; i < 5; i++) {
              >>> poly.addPoint(random.nextInt(width),
              >>> random.nextInt(height));
              >>>}
              >>>
              >>>// Fill polygon
              >>>g.setColor(Color.cyan);
              >>>g.fillPolygon(poly);
              >>>
              >>>// Dispose context
              >>>g.dispose();
              >>>
              >>>// Send back image
              >>>ServletOutputStream sos = response.getOutputStream();
              >>>JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(sos);
              >>>encoder.encode(image);
              >>>%>
              >>>
              >>>Subramaniam <[email protected]> wrote:
              >>>
              >>>> Hi,
              >>>
              >>>> The following piece of code works in tomcat but does not work in
              >weblogic.
              >>>can
              >>>> anybody please help me with this.
              >>>
              >>>
              >>>
              >>>> <%@ page contentType="image/jpeg" import="java.awt.*,java.awt.image.*,com.sun.image.codec.jpeg.*,java.util.*"%>
              >>>
              >>>> <%
              >>>
              >>>> // Create image
              >>>> int width=200, height=200;
              >>>> BufferedImage image = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB);
              >>>
              >>>> // Get drawing context
              >>>> Graphics g = image.getGraphics();
              >>>
              >>>> // Fill background
              >>>> g.setColor(Color.white);
              >>>> g.fillRect(0, 0, width, height);
              >>>
              >>>> // Create random polygon
              >>>> Polygon poly = new Polygon();
              >>>> Random random = new Random();
              >>>> for (int i=0; i < 5; i++) {
              >>>> poly.addPoint(random.nextInt(width),
              >>>> random.nextInt(height));
              >>>> }
              >>>
              >>>> // Fill polygon
              >>>> g.setColor(Color.cyan);
              >>>> g.fillPolygon(poly);
              >>>
              >>>> // Dispose context
              >>>> g.dispose();
              >>>
              >>>> // Send back image
              >>>> ServletOutputStream sos = response.getOutputStream();
              >>>> JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(sos);
              >>>> encoder.encode(image);
              >>>> %>
              >>>
              >>>
              >>>> Thanx in advance.
              >>>> regards,
              >>>> Subramaniam
              >>>
              >>>--
              >>>Dimitri
              >
              >
              >--
              >Dimitri
              

Maybe you are looking for

  • Unknown error message when using Application Loader

    Does anyone have any insight as to what might be causing these? Thank you.

  • How to add iphone user agent in safari browser running on windows xp

    How to add new user agent (iphone user agent) to safari browser(version 3) which is running on windows xp os . thanks in advance

  • Problem use SQL query in coding report with SBO

    Hi everyone! I have problem in execute query to delete and create a report with SQL 2000 in SAP. Try         oForm.DataSources.DataTables.Item(0).ExecuteQuery("DELETE FROM rptReport") Catch ex As Exception End Try          oForm.DataSources.DataTable

  • Most inept customer service ever

    I've been without phone service and have sporadic internet access for the past four days. I'm home sick with no phone for doctors/friends/family to reach me. I called 7/10 for repair (it's a hard short in the outside cable - this has happened before

  • Mail sending pro

    REfresh : it_message. clear   : it_message[].   APPEND 'Hi Sir/Madam,' TO it_message.   APPEND '' TO it_message.   APPEND 'Kindly approve the submitted leave request' TO it_message.   APPEND '' TO it_message. Fill the document data. gd_doc_data-doc_s