Questions tagged [overlap]

Two or more elements overlap when they partially or totally cover one another.

Two or more elements overlap when they partially or totally cover one another.
The way to find if the elements overlap or not is to test if one elements begins before the second one ends, while the second one begins before the first one ends.

For example, here are all of the ways two lines can overlap:

1.
s1|--------|e1
s2|--------|e2


2.
s1|-------|e1
     s2|--------|e2


3.
     s1|--------|e1
s2|--------|e2


4.
s1|-------------------|e1
     s2|--------|e2


5.
     s1|--------|e1
s2|-------------------|e2

Note that s1 is always smaller than e2, while s2 is always smaller than e1.

This is not the case when the two lines do not overlap:

1.
s1|--------|e1
                 s2|--------|e2


2.
                 s1|--------|e1
s2|--------|e2

Note that either s1 is bigger then e2 or s2 is bigger then e1.

The actual data type of the elements is completely irrelevant as long as it's comparable.

Therefore, to check if two elements overlap each other, all you need to do is this: (pseudo code)

If a.Start < b.End AND b.Start < a.End Then
    Overlap
Else
    No overlap
1695 questions
0
votes
2 answers

Overlapping TextView on setText()

I've a strange problem to set text in a TextView on Android. When I try to set text in my code, the result is very strange. See the image to understand: I've a layout as is:
user3449772
  • 731
  • 1
  • 14
  • 26
0
votes
4 answers

Overlapping divs in HTML/CSS

I need some help with my website html/css code. The site looks nice(to me), but if someone has a small 17" monitor, or if you zoom in the website, the divs in my info bar overlap each other and it looks awful. It's messy,sorry, but I have been…
luk492
  • 342
  • 2
  • 13
0
votes
2 answers

Footer overlaps content when content is 100%

What I want is that my .content_pro always sticks to the top of the footer, what resolution your screen is. But when I say height: 100% it gets under my footer. I'. struggling with this for a few hours but it won't work. Here is my HTML &…
wbjari
  • 151
  • 1
  • 2
  • 10
0
votes
1 answer

How to overlap a buffer in Objective-C

I'm trying to do FFT on the iPhone, and I realised that I had not overlapped my input prior to windowing. I was wondering if anyone could give me some insight on to how to properly overlap my input buffer. I am wanting to overlap bufferSamples by a…
jacob
  • 31
  • 1
  • 4
0
votes
2 answers

Layout of ListView is overlapping

Just now the layout in my Listview has gotten slightly messed up: The textviews in every row are now wrapped while they should be free to fill the screen horizontally. EDIT: updated text to more accurately describe the current situation. EDIT2: This…
Anubis
  • 1,052
  • 2
  • 13
  • 28
0
votes
2 answers

how to identify time overlap in r

I have a dataframe (df) with admission and discharge dates of patients, with 4 columns: ID, admitDate (as date), dcDate (as date), los (length of stay in days). $ admitDate : Date, format: "2009-09-19" "2010-01-24" "2010-09-30" ... $ dcDate …
user3399918
  • 25
  • 1
  • 1
  • 5
0
votes
7 answers

css horizontal menu is outside of round div layer

I am trying to make my horizontal menu have round edges, however the inner "li" elements seem to overlap the div layer. Here is an example for what I mean:
Kevin M
  • 1,060
  • 11
  • 25
0
votes
1 answer

CSS Floated divs are overlapping on window resize. How do I stop this?

I have just re-done my website at www.chartoonz.com I have created a wrapper div in which I have placed a div with a links to my videos on vimeo. I float this div left, next to it I have floated a div with some text about the movie and floated it…
0
votes
2 answers

Android display image like Facebook/Hangout/Gallery with pinch to zooma and overlays menu

I will make an activity that download an image from server and display it with trasparent overlay menus (sherlockactionbar for navigation bar, and a trasparent custom menu at the bottom of the screen). Style like facebook image viewer or hangout…
Tenaciousd93
  • 3,140
  • 4
  • 29
  • 51
0
votes
1 answer

Overlapping elements

On this site http://nutritiousinfo.com I am trying to get the menu navigation element to overlap the header. I tried changing the top margin of the menu to -35px and it looked fine until I refreshed it and it jumped back down again. Here is my CSS…
user3494066
  • 1
  • 1
  • 3
0
votes
1 answer

Highcharts stacked column dataLabels overlapping

I set the 'max' to '100' (for 100%) and 'min' to '0'. Thanks! UPDATE [http://jsfiddle.net/3kVJS/2/]
WilliamTeodoro
  • 61
  • 1
  • 11
0
votes
1 answer

How to determine image overlap through range of X's and Y's in Java

So I have been attempting to create a little game of "frogger" only I used a trainer instead of a Frog and Pokemon instead of cars. Pretty simple. So far I have everything moving and resetting according to plan, but the problem arises when I try…
Lilnonie
  • 13
  • 5
0
votes
1 answer

Overlap background (and overlap image) on Nexus 5

This is the Overlap Background (or Overlap Image) problem which I only get it on Nexus 5 Emulator while testing. I have not tested on Nexus 5 Device, but I think the Emulator should show quite correct. This is my coding indicated how to support…
Huy Tower
  • 7,162
  • 13
  • 49
  • 81
0
votes
2 answers

JScrollPane, overlapping panels inside

I've currently got a JScrollPane in which I am placing panels inside of. For some reason the panels are not being placed side by side, rather they are overlapping on each other in the top left hand corner of the JScrollPane. public class UI extends…
Joe Bid
  • 335
  • 6
  • 21
0
votes
1 answer

overlapping rotated buttons - on click behind one comes to front

I'm programmatically creating two overlapping buttons in a RelativeLayout. Both buttons have different angles so you can press each one. When I press the button on the bottom it comes to front. What should I do so that the button remains behind the…
bluerob
  • 91
  • 7
1 2 3
99
100