Image not aligning right - image

I have an image within a controlBarContainer that is not wanting to align right for some reason. My code looks like this:
<s:controlBarLayout>
<s:HorizontalLayout/>
</s:controlBarLayout>
<s:controlBarContent>
<mx:Text color="#EC6500">
<mx:htmlText>
<![CDATA[
<b><font size="18" font-weight="bold">Institut für Angewandte Geowissenschaften</font></b>
<b><font size="12">Forschungsprojekte: Geo-Ressourcen und Geo-Risiken</font></b>
]]>
</mx:htmlText>
</mx:Text>
<mx:Spacer width="100%"/>
<s:Image height="100" smooth="true" smoothingQuality="high"
source="#Embed(source='../images/logo.png')"/>
</s:controlBarContent>
Is there any way I get the image to align right while aligning the text left?

I think if you set the containers width (ControlBarContent) to 100%, youll get the desired alignment.

Actually, it's already algn to reight, becuase the container is not wide enough, so you think it's not working.
Try modify the parent container to 100%:

I am not exactly sure what the issue was, but after messing around with the code for a bit, I noticed that there appeared to be an issue with the image. I imported the image into GIMP and resized it then saved it as a png and jpg. Both the png and jpg files seemed to embed just fine. If any has any theories as to what might have been going on, please let me know for the future.

Related

Firefox displaying image colours incorrectly

I have a website that incorporates a logo in to the header. This logo has a background that is the same colour as the background of the header, yet in Firefox the colour is different.
I can find various articles alluding that the 'colour profile' being the culprit, but I cannot find out how to fix this issue.
Quite why anyone would think that changing the colour of an image is the way forward I don't know, but it looks very poor, so I'd be grateful for some suggestions on how to fix this.
To create the original image I used GIMP, and it has been exported as a PNG.
Here is a section of the header so that you can visually see what I mean -
Since you do not provide the original image, I have to make an educated guess:
Your image most likely has a (broken, incorrect) color profile embedded. Fix or remove the color profile and you should be good. See the documentation of your favorite tool on how to do that.
You should use some tool like tweakpng to check if the PNG has a color profile, and remove it.

Scale down to fit an image in FOP

I am using FOP version 1.0 to create PDFs. In one of the pages I'd like to display an image (2552 x 4200 pixel) and scale it down if it doesn't fully fit on the page. As far as I could see on the mailing list the recommended way of doing this would be following:
<fo:external-graphic inline-progression-dimension.maximum="100%"
content-height="scale-down-to-fit"
content-width="scale-down-to-fit"
src="..."/>
Unfortunately, that still doesn't display the whole image. The lower part of the image is cut off. Can anyone give me a hint on what I am potentially doing wrong?
I found this page here explaining how scaling works with XSL-FO.
Essentially, this is the snippet that I used to make it work:
<fo:external-graphic
src="url('...')"
width="100%"
content-height="100%"
content-width="scale-to-fit"
scaling="uniform"
xsl:use-attribute-sets="img"/>
I found that width="100%" was the missing piece in your own attempts. Hope this helps future visitors.
Defining the exact height and width of the "viewport":
.
If you don't specify the viewport then FOP won't know what to scale your image to.
It can guess, but not know precisely.

Image resize issue in Mozilla Firefox for windows

I am having some weird issues. I have a large image which is being shrunk to size 30px in the img link so:
img src="/company/images/logos/1.png" height="30px"
On all browsers and computers it looks fine except for firefox on a windows. I found out that when i rid the height constraint it looks fine but when i add the "30px" it looks messed up.
Any ideas on what i might need to do?
I'm guessing you're talking about issue where the default Firefox image resizing algorithm makes the image look "jagged".
In general, it's better to not let the browser resize the image.
You should instead make a version of the image that is already the correct size.
I'm not aware of a way to make the image look good when downscaling in Firefox.
See here for a comparison. (I used Firefox 3.6.15 / Windows 7)
If anybody has a way to make the first image downscale smoothly in Firefox, I'd like to know.

Same image displaying differently in different browsers

Here is an image:
When I load this image in different browsers, it shows differently.
Take a look at the result:
I spent a lot of time on this, but I can't understand why it happens.
I have only theories: something wrong with color profiles, or bad image structure, or something else - maybe special copyright measures?
Why is this happening?
The image is a CMYK image, which IE and Safari apparently do not support. Converting it into an RGB image solved the problem for both Safari and IE.
RGB Version:
The color's been changed though, so you'd probably want to run it through Photoshop and edit the color balance to get the colors right.
There could be something wrong with the image. Open it in some image editor like GIMP and check if it gives some warnings. Try converting the image to some other format(png?) and see if the browsers render it correctly.

iPhone images display

I want to know if there is any way to append something like white border around iPad image thumbnails without too much performance issues?
Something like in XHTML\CSS where you get Polaroid like appearance.I think you may have got faint idea.
Any guidance is highly appreciated.
Fastest way would be to draw a frame around your images if they're all of the same size (your thumbnails).

Resources