microsoft / microsoft/automatic-graph-layout
Microsoft.Msagl.WpfGraphControl.GraphViewer.ObjectUnderMouseCursor is always null
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 1.5k
- Forks
- 319
- Avg merge
- 38m
- Merged PRs (30d)
- 1
Description
Edit the MinWpfApp sample and add the following code at the end of the GraphViewer initialization:
graphViewer.MouseUp += (o, args) => {
var viewer = (GraphViewer) o;
var obj = viewer.ObjectUnderMouseCursor;
};
obj is always null when clicking on nodes. Also, args.Clicks seems to always be 1 even on double clicks (though this might be a separate issue)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Open GraphLayout/Samples/MinWpfApp/MainWindow.xaml.cs around line 38 and reproduce the issue using the added MouseUp handler. Trace how GraphViewer determines ObjectUnderMouseCursor when a node is clicked, and verify the behavior in the MinWpfApp sample. Done means the clicked node is exposed through ObjectUnderMouseCursor; treat the double-click count as a separate question unless the investigation connects them.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100