dotnet / dotnet/dotnet-api-docs

When the left side of one rectangle overlaps with the right side of the other rectangle, rectangles are considered not intersecting.

Offen
#764 2 Kommentare 1 Reaktion 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

area-System.Drawing Pri2 unspecified/svc untriaged
Vorherrschende Sprache
C#
Sterne
950
Forks
1.7k
Ø Merge
2 T. 19 Std.
Gemergte PRs (30 T.)
52

Beschreibung

It would be good to clarify how IntersectsWith method handles rectangles that overlap borders, X == r.X + Width. WinForms consider this case as not an intersection. WPF considers this as an intersection but does not document this fact either:https://docs.microsoft.com/en-us/dotnet/api/system.windows.rect.intersectswith?view=netframework-4.7.1#System_Windows_Rect_IntersectsWith_System_Windows_Rect_
The difference between the frameworks is confusing. This could be documented with a sample or even a pointer to reference source website.

Another good note would be to mention that this method ignores integer overflows and might be inaccurate due to this fact.


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Öffne xml/System.Drawing/Rectangle.xml und suche den Eintrag IntersectsWith(Rectangle). Vergleiche seine aktuelle Formulierung mit dem im Issue beschriebenen Verhalten von WinForms und WPF und dokumentiere Rechtecke, die sich an den Rändern berühren, sowie die Einschränkung durch Ganzzahlüberlauf; füge optional das angeforderte Beispiel oder einen Link zur Reference Source hinzu. Die Aufgabe ist abgeschlossen, wenn die API-Referenz beide Verhaltensweisen klar angibt.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
csharp
Bereich
documentation
Issue-Typ
Dokumentation
Schwierigkeit
1/5
Geschätzter Aufwand
1-3 Stunden
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
38/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.