inglonias / vgraph Goto Github PK
View Code? Open in Web Editor NEWA digital piece of grid paper
License: MIT License
A digital piece of grid paper
License: MIT License
Add the ability to fill in certain sections of the page with a solid color, either with arbitrary polygons or governed by nearby lines.
Add a tool for drawing ellipses that are not perfectly round.
The two click points would be the two radii of the ellipse, and the center would be the third point of a right triangle with the other two points.
Need keyboard shortcuts.
The code for this exists and will be merged shortly.
When the canvas becomes very large for whatever reason, either because the user has created a very large canvas or they zoom in to the maximum level, VGraph noticeably slows down. This is because it is drawing the entire canvas regardless of how much of it is actually visible.
This would be a tricky one to fix, but I'm putting it in the issues list for anyone who wants a challenge. The obvious fix would be to stop drawing things that aren't currently visible, but considering how the code works right now, I'm not sure how you would go about doing that without redoing the way rendering happens entirely.
I would like to ability to draw rectangles and "circles", in the sense that I want to be able to draw an N-gon that most closely resembles an arbitrary circle while still obeying all currently existing rules of lines on the page. Rectangles are easy, but I don't know the math behind creating arbitrary polygons that represent circles at given sizes.
If a line goes from, say, (0, 0) to (5, 5), and another line goes from (0, 0) to (3, 3), and then the merge tool is used, these two lines will be merged incorrectly, replaced at first with a line going from (3, 3) to (8, 8), but when the mouse moves, the actual line is between (3, 3) and (5, 5). This is incorrect. The behavior in this case should be to simply delete the shorter line.
A special case for lines merging with these "subset" lines needs to be created to account for this, and a unit test must be made to ensure this behavior does not continue.
This was taken after merging lines.
I want to be able to mirror stuff.
Expose the ability to configure default options for various elements of VGraph. Ideally, these options would be kept in an ini or JSON config file outside of the program, but still be possible to edit from some kind of options screen within VGraph.
Add an option to highlight center lines on the grid background. A single line for even dimensions and a pair of lines for odd dimensions.
If the page can be scrolled up and down with the scrollbar and it's in focus, pressing PageUp and PageDown will cause the page to scroll up and down rather than zoom in and out.
I should have some unit tests. This depends mainly on whether or not I can automate a build and release pipeline using GitHub Actions. This is apparently possible but not intuitive.
Add previews for what each tool results in.
It would be useful for certain tools to be able to draw in an "odd" fashion. For example, a circle with a radius of 1.5 rather than 1, 2.5 rather than 2, and so on.
While I haven't worked out the math yet, I have an idea for an implementation style - Everything that implements IDrawTool
must provide a DrawWithToolOdd
method that returns a LineSegment[]
. The default implementation of this would be to just call DrawWithTool
as normal, but for tools where it matters, there can be a different implementation.
Add at least a few steps of undo/redo.
Create an eyedropper tool that lets users pick up line colors they want to reuse.
With the addition of odd mode mirroring, the automated test needs to be updated to test that situation as well.
Allow users to undo moving labels and lines.
Implementation:
The trickiest part of this is the situation where a user moves an element or set of elements, and then selects a different element or group of elements to move. We can't just assume that once the user stops moving lines, that's when we can add the undo state. It may be necessary to change the way undo and redo are handled away from simply saving copies of every element, and instead transitioning to a delta object of some sort.
This is caused by the new framerate limiter. A redraw can only be forced when the framerate timer says so, and if it doesn't say so, then the screen is blank until it does. This is usually a minor issue - simply wiggling the mouse brings the screen back, but it doesn't look good.
Allow users to add text labels to arbitrary points on the grid using a text tool and associated data layer.
I may be able to port VGraph using MAUI. Not sure how easy or difficult that would be, since the GUI is pretty much married to WPF (and to a lesser degree, Windows Forms), but it's worth looking at if I ever get bored. Alternatively, I may be able to rewrite the front-end using Xamarin or something.
Someone please help I don't know how to do this.
The ability to import a background image to trace over would be a huge boon for e.g. translating orthographic drawings into FTD replicas.
Some auxiliary features for usability:
Two line segments that connect and have the same angle should be mergeable.
Allow the user to edit more than one image at a time through the use of tabs.
The most difficult part is ensuring that each tab is completely separated from one another. Notable examples include but are not limited to:
The drawing tools should be in a drawer on the side of the window, rather than hidden away in the Tools menu. The Tools Menu should be for things like mirroring the drawing, and merging lines.
Use a WPF color picker to add a color changing feature.
https://docs.microsoft.com/en-us/uwp/api/windows.ui.xaml.controls.colorpicker?view=winrt-22000
Right now if you want to resize the canvas, you can either do some clever tricks with importing files, or you change the values in the save file directly. While not difficult if you know how to do it, it's tedious and there really should be a way to change the canvas size in the program.
Lines can be pushed out of alignment if more than one of them is selected. The lines on the edge won't go off the canvas, so if you move in one direction enough, they'll all bunch up on the side of the page. Worse, you can't really undo moving lines around right now.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.