about summary refs log tree commit diff stats
path: root/main.lua
Commit message (Collapse)AuthorAgeFilesLines
* more intuitive point delete from polygonsKartik K. Agaram2022-05-151-2/+18
|
* delete points or shapesKartik K. Agaram2022-05-141-12/+50
| | | | Deleting a point deletes all shapes that use it (but not other points in those shapes).
* slightly less strange now that we have the same two ways to move points as ↵Kartik K. Agaram2022-05-141-6/+18
| | | | | | | any other operation 1. hover over point, hit C-v 2. press mouse on point, hit v
* slightly strange way to move pointsKartik K. Agaram2022-05-141-5/+44
| | | | | | | | | | | | Hover mouse on a point, hit a hotkey (C-v), then move mouse without clicking, and click to finalize. The hotkey is like a pointer tool, except you have to already be at the thing you want to erase. And it's slightly inconvenient to move multiple points one by one. In the process I also fixed a bug: keychord clauses should always specify the mouse button state.
* changing your mind mid-shapeKartik K. Agaram2022-05-141-2/+30
| | | | | | | | | line->circle circle->line line->polygon polygon->line circle->polygon polygon->circle
* new mode: circle arcKartik K. Agaram2022-05-141-0/+81
| | | | | We start out drawing a circle, but instead of releasing the mouse we hit 'a'.
* new mode: circleKartik K. Agaram2022-05-141-0/+28
|
* new mode: polygonKartik K. Agaram2022-05-141-0/+55
| | | | | Polygons are closed. Add vertices to them by pressing 'p' while holding down the mouse.
* .Kartik K. Agaram2022-05-141-1/+1
|
* bugfix: clipping in line and manhattan modeKartik K. Agaram2022-05-141-13/+29
| | | | Thanks Kiran and Ravi.
* new mode: manhattanKartik K. Agaram2022-05-141-2/+41
|
* .Kartik K. Agaram2022-05-141-2/+2
|
* make points easier to acquireKartik K. Agaram2022-05-141-4/+8
|
* make point near focus 'pop'Kartik K. Agaram2022-05-141-1/+3
|
* snap lines to nearby pointsKartik K. Agaram2022-05-141-1/+3
|
* add a level of indirection to vertices of shapesKartik K. Agaram2022-05-141-37/+68
| | | | This is like Sketchpad.
* .Kartik K. Agaram2022-05-141-1/+1
|
* draw lines by defaultKartik K. Agaram2022-05-141-1/+1
| | | | Freehand strokes are a special case. Let's ignore them for a bit.
* bugfix: keep the click to create a new drawing from creating a new shape in ↵Kartik K. Agaram2022-05-141-14/+14
| | | | | | the drawing Easiest way to do this is to keep the screen areas for button and drawing disjoint.
* experimental approach to combining keyboard and mouse while drawingKartik K. Agaram2022-05-141-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Desired properties: - fluently draw lots of precise drawings - requires expressing lots of different kinds of constraints - always know what pressing a key is going to do - when typing, don't care where the mouse pointer is Less important: - discoverability, learnability. Provide a hotkey for help. Current plan: - chorded keys to modify drawings while mouse button is not pressed - unchorded keys to modify drawings only while mouse button is pressed - make changes while drawing a shape by pressing a key while mouse button is pressed - make changes to a drawing by hovering mouse pointer at a shape and pressing a key (unary operators) - add constraints after drawing by hovering mouse pointer at a shape, pressing a key and moving mouse pointer to a second shape (binary operators) - almost any change can be made to a shape after it's drawn (inspired by Sketchpad) - keys pressed while drawing a shape act as abbreviations to performing the action after drawing First example in this PR: - you press mouse button, start drawing freehand - you realize you want a simple line, not a freehand stroke - without releasing the mouse button, you press 'l' - now you're drawing a straight line You could also release the mouse button and finish the stroke, then press 'ctrl-l' while hovering the mouse pointer on the stroke to turn it into a line. There's an asymmetry here. Strokes require a lot more information, so while you can turn a stroke into a line, you can't turn a line into a stroke. Strokes are an exception where you can't switch to freehand mode after you start drawing. You have to press C-f before drawing.
* bugfixKartik K. Agaram2022-05-141-1/+1
|
* beginnings of support for multiple shapesKartik K. Agaram2022-05-141-43/+114
|
* color close to drawingKartik K. Agaram2022-05-141-1/+1
|
* Devine's suggestion to try to live with just freehandKartik K. Agaram2022-05-141-0/+17
| | | | | | | | | | | | https://merveilles.town/@neauoire/108301005736317873 Drawbacks: Smoothing eliminates high-frequency noise but not low-frequency bumps. Making a drawing end at the start point is very challenging. Still perhaps a useful addition to the toolbox for now. I'm going to need a cambrian explosion of tools in the toolbox for a while before I prune.
* revert: back to freehandKartik K. Agaram2022-05-141-21/+44
|
* switch from freehand to just straight linesKartik K. Agaram2022-05-131-44/+21
|
* store device-independent coordinates inside drawingsKartik K. Agaram2022-05-121-11/+25
|
* slightly tweak boundary between concernsKartik K. Agaram2022-05-121-1/+1
|
* fix a typoKartik K. Agaram2022-05-121-1/+1
|
* make space for multiple kinds of widthKartik K. Agaram2022-05-121-3/+3
|
* fix 2 bugs in line selectionKartik K. Agaram2022-05-111-2/+5
|
* turn strokes into horizontal and vertical linesKartik K. Agaram2022-05-111-0/+16
|
* refactorKartik K. Agaram2022-05-111-8/+15
|
* simplest possible way to straighten strokesKartik K. Agaram2022-05-111-0/+21
|
* more lightweight; select just the stroke at the mouseKartik K. Agaram2022-05-111-11/+2
|
* selecting a strokeKartik K. Agaram2022-05-111-2/+47
|
* bugfix: restrict strokes to the drawing they started inKartik K. Agaram2022-05-111-4/+15
|
* reorgKartik K. Agaram2022-05-111-4/+4
|
* spacingKartik K. Agaram2022-05-111-3/+3
|
* inlineKartik K. Agaram2022-05-111-5/+1
|
* renameKartik K. Agaram2022-05-111-3/+4
|
* clean up repl functionalityKartik K. Agaram2022-05-111-32/+7
| | | | Now we have separate keywords for returning vs drawing something.
* clip drawings inside the borderKartik K. Agaram2022-05-111-2/+2
|
* lighter border for figuresKartik K. Agaram2022-05-111-1/+2
|
* intermingle freehand line drawings with textKartik K. Agaram2022-05-111-7/+69
|
* confirm that we have access to all of the love APIKartik K. Agaram2022-05-021-4/+14
| | | | | | | | love.graphics.line(1, 1, 500, 500) However, we're now no longer printing results or errors. Time now to design the data model. When do we (re)evaluate code. When do we display results. Where do errors go.
* don't rely on defaultsKartik K. Agaram2022-05-021-0/+1
|
* backspaceKartik K. Agaram2022-05-021-0/+10
|
* handle chordsKartik K. Agaram2022-05-021-26/+21
| | | | | For shift we'll mostly rely on love.textinput. For the rest I've created a simple driver.
* little Lua repl on hitting ctrl-rKartik K. Agaram2022-05-021-1/+30
|