Reputation: 938
I have several adjacent elements that I calculate their position according to another element on the page.
The elements should surround that element.
The problem is that on IE, when you zoom to a certain point, there appears a single line of pixels between those surrounding elements.
I created a jsfiddle to demonstrate the issue:
https://jsfiddle.net/0vcomjsk/
The divs in the fiddle are positioned according the the height and top of the previous div:
#first {
width: 100%;
height: 100px;
top: 0;
left: 0;
}
#second {
width: 50%;
left: 50%;
top: 100px;
height: 100px;
}
#third {
width: 100%;
top: 200px;
left: 0;
height: 100px;
}
As you can see in that fiddle, the red elements, surround a rectangle on the left.
picture:
If you open this page on IE and zoom enough, you would be able to see an empty line of pixels between those divs.
picture:
Upvotes: 0
Views: 21
Reputation: 938
I ended up changing the opacity of the divs to 100%, making them overlap each other and putting all of them in a new div with opacity 50%. It solved the issue :)
Upvotes: 0
Reputation: 66
Try and set the Height and Top in percentage instead of pixels.
Upvotes: 1