background-repeat

CSS multiple Background Images both repeat-x

限于喜欢 提交于 2020-02-05 08:25:32
问题 I try to get multiple background images in one div at the moment. Both must repeat-x. The first image should start at the top-left point up to 50% of the div. The second should start at the middle to the right end of the div. I tried the following: .myDiv { background-image: url('image1.png'), url('image2.png'); background-repeat: repeat-x, repeat-x; background-position: left top, center top; background-size: 50% 100%, 50% 100%; } My problem is that only image1 is shown. 回答1: Set two

CSS multiple Background Images both repeat-x

耗尽温柔 提交于 2020-02-05 08:24:18
问题 I try to get multiple background images in one div at the moment. Both must repeat-x. The first image should start at the top-left point up to 50% of the div. The second should start at the middle to the right end of the div. I tried the following: .myDiv { background-image: url('image1.png'), url('image2.png'); background-repeat: repeat-x, repeat-x; background-position: left top, center top; background-size: 50% 100%, 50% 100%; } My problem is that only image1 is shown. 回答1: Set two

Why isn't the footer going all the way from left to right?

折月煮酒 提交于 2020-01-06 07:01:52
问题 The background of my css class footer does not go across the entire width of the browser depending on how wide I keep the browser. It is making the page look odd because the footer is ending before the main content ends. The site is up at avidest.com so you can see what I'm referring to. Here is the css: .Footer { width: 100%; padding:10px 0; margin:0px 0 0 0; text-align:center; border-top:1px solid #b3b3b3; background:#d9d9d9; background-repeat: top-repeat-x;} The css was originally: .Footer

ActionBarSherlock background does not repeat on pre ICS versions

一个人想着一个人 提交于 2020-01-01 11:41:51
问题 I'm moving my app's ActionBar to ActionBarSherlock and I'm trying to customize the background with a tiled background. I'm testing my code on 2 real devices, one running Android 2.1 and the other running Android 4.0.4. The code below is working on the ICS device (the background does repeat) but not on the Eclair one (the background is stretched instead of repeating). I've also tested this on Android 2.3 emulator and the background does not repeat too. It seems the tileMode="repeat" is only

ActionBarSherlock background does not repeat on pre ICS versions

ⅰ亾dé卋堺 提交于 2020-01-01 11:40:04
问题 I'm moving my app's ActionBar to ActionBarSherlock and I'm trying to customize the background with a tiled background. I'm testing my code on 2 real devices, one running Android 2.1 and the other running Android 4.0.4. The code below is working on the ICS device (the background does repeat) but not on the Eclair one (the background is stretched instead of repeating). I've also tested this on Android 2.3 emulator and the background does not repeat too. It seems the tileMode="repeat" is only

can you create space between background image repeats?

我们两清 提交于 2019-12-19 05:53:03
问题 Is it possible to repeat a background image, but specify a number of pixels before the next repeat starts. i.e. background: url(img.png) [after 40px] repeat-x; I don't want to add empty space to the image. 回答1: background-repeat: space; background-repeat: round; // round(520 / 100) = round(5.2) = 5 The browser will render five images in the space but adjust the image width to 104px (520px / 5). The image is made wider to fit the container. Full details here or read Background Size property 来源

Background repeat doesn't seem to work in IE6

安稳与你 提交于 2019-12-12 06:16:03
问题 I ve applied a background to my page like this, body { background:#FFFFFF url('images/color.png') repeat top left; color:#666666; font-family:Arial,Helvetica,sans-serif; font-size:80%; font-style:normal; font-variant:normal; font-weight:normal; white-space:nowrap; margin:0 auto; height:100%; } This seems to work in IE7,firefox and chrome but certainly not in IE6. 回答1: IE6 hates pngs..:) leave alone rendering them in background..! you will need some sort of PNGFix for this.. I usually use this

background repeat tiled bgImage inside an sprite image?

痞子三分冷 提交于 2019-12-12 01:55:26
问题 Lets say this is our sprite (please ignore the black forms) Is there a way to repeat the gray -on the left- tiled image so it looks like a repeated background? 回答1: Nope, as far as I know, this is not possible, not even in CSS3. You will need to separate the images. There is the background-clip property but that controls the clipping of the background image in relation to its container , which is something else. 来源: https://stackoverflow.com/questions/7796210/background-repeat-tiled-bgimage

ActionBarSherlock background does not repeat on pre ICS versions

懵懂的女人 提交于 2019-12-04 09:56:53
I'm moving my app's ActionBar to ActionBarSherlock and I'm trying to customize the background with a tiled background. I'm testing my code on 2 real devices, one running Android 2.1 and the other running Android 4.0.4. The code below is working on the ICS device (the background does repeat) but not on the Eclair one (the background is stretched instead of repeating). I've also tested this on Android 2.3 emulator and the background does not repeat too. It seems the tileMode="repeat" is only working on ICS. themes.xml: <style name="Theme.Opheodrys.Base" parent="Theme.Sherlock.Light"> <item name=

Why background-repeat: no-repeat doesn't work with .svg images in Opera 12?

烂漫一生 提交于 2019-12-02 12:38:15
问题 I got stuck with a strange problem in Opera 12: I have an .svg image which is linked within my css code. When I resize to zoom-out the page where the image is displayed, Opera repeats the image as if I didn't use the "no-repeat" value in background-repeat. What am I missing? Here is my css code: .svgImg { background: url("../img/img.svg") no-repeat; height:100%; width:100%; } I also tried this: .svgImg { background: url("../img/img.svg"); background-repeat:no-repeat; height:100%; width:100%;