resizing chrome theme image to fit screen size - google-chrome-extension

is there a way to make the background image of chrome theme resize with the height of the window? If so, can I also make the image resize with the height until it hist a certain ratio, and then resize with the width of the window?

It's not possible. Chromium source code doesn't have any stretching/sizing modes as you can see: theme_properties.h, theme_properties.cc and theme_service.cc
I've tried specifying an SVG image with width="100%" height="100%" for the background but it wasn't rendered, looks like only raster images can be used (WEBP, JPG, PNG, etc).

I tried use jpeg format, it resized itself, without anything added to manifest.json

Related

How to rasterize svg to png without aliasing effect with "data:image/svg+xml" with Inkscape?

I have a problem while export svg to png with svg which includes some element image objects using Inkscape.
Example:
<image xlink:href="data:image/svg+xml;base64,PD94bWwgdm....Zz4=" x="-312" y="-139" width="624" height="278"></image>
Notes:
- When I open svg in web browsers, when zoom in browser images are nice, and not have aliasing effect.
- But using Inkscape command : /Applications/Inkscape.app/Contents/Resources/bin/inkscape /test/test.svg -e /test/test.png -d 300 --> image is aliasing.
Here is result on browser and output png file:
Here is my files:
1. https://drive.google.com/open?id=1Wjt-QnX4iPL3QYHfYLI7wVfq26yBCe3e --> svg file which include with svg data "data:image/svg+xml"
2. Exported png using inkscape with dpi 300
https://drive.google.com/open?id=1k171_ARwnw0-5iyM7vwJsH_h6tFWpb1v
Please help me!
Thank you!
Use a raster file that uses the correct export dpi
Scale it to the correct size in Inkscape
Position it at a full pixel value
(untested, but should work)
In (future) Inkscape 1.0, you can also uncheck the antialiasing functionality in the export dialog, but not sure how that affects raster images. It might not look good.

Image used as pattern in inline SVG has greenish tint

I have this inline SVG element. Some of its sub elements use image patterns. (In the attached photo, the SVG object is on the left and the image with correct color is on the right). A very strange greenish hue is affecting all image patterns and images in the SVG which have patches of white in the original images used. What could be the reason? I've already checked this both in Firefox and Chrome. Same problem shows in both browsers. I used SVG transforms (rotate, scale, translate) to manipulate the images but never a command to change the colors..
EDIT 2017-09-24 (screenshot in Safari) - Safari displays the correct color

OpenModelica svg icon for blocks

The svg icon of a block is not displayed. Here's how I set it:
I switch to Icon view
Click on Bitmap
Draw a rectangle
In Bitmap properties I select the svg file through Browse (the option for svgs exists). The svg file is in the same folder as the .mo file.
Click Ok and the svg icon is not displayed - I get nothing (like a white icon - I can only see the corners of the bitmap rectangle). The svg file was created in Inkscape and saved as Plain svg.
Is this svg icon option not implemented yet but will be in the near future? or am I doing something wrong?
The svg option was there by mistake. The supported formats for bitmap are PNG, BMP and JPEG. I have fixed it now in r18662.
Adeel.

Logo image with text on css3 gradient background of web page

In a web page there is a gradient (in body tag) using CSS3. Moving next and adding image (logo with site name) I realized page gradient and image both has different colors. It is because web page has a background generated by CSS3 and image has a fixed color as background and both are different.
What I have tried ?
add image as background of a div and also as a img tag.
applying gradient on div
but no luck.
How it can be managed ? Please guide.
Thanks
Cant you just save the text of your logo as a .png with a transparent background? If you've added the gradient to your body tag it will change when the browser window expands and contracts
you have to save your logo image with transparent background....you open the psd file of the logo and disable the visibility of the background layer and then save it as a png image.

scaling svg figure

I tried to resize svg file to be opened in illustrator with smaller width and height(pixels or cm), I did this by changing width, height and viewBox attributes in <svg> tag, but it doesn't work at all. By search I have found that transform attribute via matrix value affects the real resizing of the figure, any ideas about ready made functions or scripts using python or librsvg to successfully scaling the svg figure, by the way I'm using inkscape to produce svg files. THANKS
You could try svg scour, that should be able to find a good viewBox to use (note spellning and uppercase 'B'). Then change only the width and height attributes to be whatever you want, and hopefully that should work.

Resources