sheaf
64e45f126b
Refactor module hierarchy, use internal records
2022-02-11 22:05:13 +01:00
sheaf
eba08a6edd
add first-class functions to brush language
2021-05-25 13:45:21 +02:00
sheaf
5ff935b4b2
update render & select for new brush manipulation
2021-05-24 17:37:26 +02:00
sheaf
15d50f8d76
add signed curvature computation
2021-05-16 00:33:58 +02:00
sheaf
7431e8ba67
compute roots of envelope equation
2021-05-15 23:27:21 +02:00
sheaf
df2469487d
add cubic Bézier crunode computation
2021-05-15 21:24:58 +02:00
sheaf
9f16cff978
fix brush join orientations
2021-05-13 22:07:49 +02:00
sheaf
570a593f4f
fix stupid error in quadratic solver
2021-05-12 15:16:26 +02:00
sheaf
2983943363
compute correct open stroke caps
2021-05-12 13:58:30 +02:00
sheaf
c64a4140c4
fix orientation of brush joins
2021-05-10 23:51:05 +02:00
sheaf
b46dc2a140
start reworking brush stroking
2021-05-10 18:02:42 +02:00
sheaf
f8b0ec2ab1
adjust spline wither framework/selection deletion
2021-05-01 20:38:11 +02:00
sheaf
a4bf83949a
fix incorrect field name in stroke hierarchy deserialisation
2021-04-30 17:48:19 +02:00
sheaf
df9b9c1f66
simplify Laguerre solver
2021-04-29 21:03:45 +02:00
sheaf
4182b78c7e
fix incorrect deflation code
2021-04-27 01:16:30 +02:00
sheaf
d604d4120e
stroke hierarchy
2021-04-26 17:18:48 +02:00
sheaf
a5fdce1133
use Seq for strokes
2021-04-26 14:34:34 +02:00
sheaf
e1c5d266eb
embed brushes inline into strokes
2021-04-26 01:17:27 +02:00
sheaf
70cab39947
write cabal version number to .mb JSONs
2021-04-25 17:50:35 +02:00
sheaf
2ee0cbbfc0
fix styling on dialog windows
2021-04-25 15:22:10 +02:00
sheaf
c3bcce58a7
use ?self to address pointer ownership warnings
2021-04-25 01:59:15 +02:00
sheaf
36a6a3ca4b
Fix file chooser crashes
2021-04-21 18:14:35 +02:00
sheaf
1b0382f3b0
Switch to GTK4
2021-04-21 15:08:33 +00:00
sheaf
a9adcba8eb
fix some errors in polynomial code
2021-02-26 01:52:52 +01:00
sheaf
5e62937f16
fix preview for first curve in path
2021-02-25 14:43:43 +01:00
sheaf
c6694e4e2f
fix bug in reverseSpline
2021-02-25 14:04:54 +01:00
sheaf
46275514ff
add stroke preview when drawing
2021-02-25 03:41:12 +01:00
sheaf
4788ab2efd
fix bug in cubic Bézier subdivision
2021-02-25 00:07:15 +01:00
sheaf
212ac4fded
use STRefs to hold cached outline data
2021-02-24 22:52:26 +01:00
sheaf
6dbade1fae
always use current viewport sizes
2021-02-23 21:52:03 +01:00
sheaf
c1cae2b69f
compute outline data concurrently
2021-02-23 20:58:53 +01:00
sheaf
b32499cc68
GHC 9.0 compatibility
2021-02-23 13:16:26 +01:00
sheaf
ab3a12c983
use assertions instead of errors, minor linting
2020-11-15 06:28:48 +01:00
sheaf
1e4bb4bddc
implement a basic brush store
...
* each stroke stores the brushes it uses by reference,
so that one can interactively edit brushes
and see the strokes be updated in real-time
* when writing to a file, we retrive the brush code
from the reference, and include that information statically
2020-11-14 23:32:23 +01:00
sheaf
393ef6f06e
Implement programmable brush framework
2020-11-12 17:34:46 +00:00
sheaf
a5ba7dcd33
use haskell-gi bugfix to improve tab reordering
2020-09-26 00:21:49 +02:00
sheaf
58ca70c1bd
optimise root-finding functions
...
* use PrimArray to represent polynomials
* add some strictness annotations
* turn on some optimisation flags
* use quadratic formula for quadratic polynomials
2020-09-19 00:43:07 +02:00
sheaf
eb8e7012aa
curve dragging support
2020-09-18 19:17:40 +02:00
sheaf
40d10b6a8e
add backend implementation of curve dragging
2020-09-17 05:47:53 +02:00
sheaf
2e9c437bd4
fix incorrect brush join computation
...
* also add some curvature calculations (unused at the moment)
2020-09-16 23:56:19 +02:00
sheaf
1c6f751a2b
improve offset tangent calculation
2020-09-15 19:07:22 +02:00
sheaf
808e37b1b3
fix issue with incorrect subdivision in fit
...
* was using `Max ( Arg t sq_dist )` instead of `Max ( Arg sq_dist t )`
2020-09-14 06:28:35 +02:00
sheaf
e3d920573d
add debug mode to visualise fitting algorithm
2020-09-14 06:03:45 +02:00
sheaf
087c29aef3
fix time-travel issue in deletion code
2020-09-11 00:37:39 +02:00
sheaf
dc11c1af15
add change descriptions for document history
...
* fix issue with accelerator key press handler
overriding the application's key press handler
* fix not being able to close tabs when no document is active
2020-09-10 21:50:35 +02:00
sheaf
7e8c2e10d1
add document history & undo/redo
2020-09-10 18:59:14 +02:00
sheaf
0a978b7c59
add hover indicator for points and guides
2020-09-09 01:23:25 +02:00
sheaf
dc6602bb79
refactor ruler subdivision handling
2020-09-08 22:20:46 +02:00
sheaf
a459467ed0
add parallelism for brush outline computation
...
* also enable varying the fitting parameters (UI todo)
2020-09-07 17:38:22 +02:00
sheaf
d501fcb76a
add ruler ticks
...
* also includes some improvements to Cairo pixel alignment
2020-09-07 15:44:08 +02:00
sheaf
777b894c06
fix accelerator key handling
2020-09-06 17:20:04 +02:00
sheaf
e4779d8af2
update "toggle guides" menu text on toggle
2020-09-06 15:31:18 +02:00
sheaf
091c1603bb
add toggle for showing guides
2020-09-06 05:32:03 +02:00
sheaf
3660cb8dce
subdivide paths by double-clicking on them
...
* still WIP:
- path mode: does not correctly interpolate brushes
- brush mode: does not propagate subdivision to other brushes
2020-09-06 04:43:28 +02:00
sheaf
9a2f123895
fix incorrect selection mode for Shift
2020-09-06 01:06:44 +02:00
sheaf
031d72a69b
create/move/delete guides: drag from ruler area
2020-09-06 00:40:56 +02:00
sheaf
930fa0ebf9
don't attempt to draw outline when brush is empty
2020-09-05 15:35:01 +02:00
sheaf
a098eb6471
refactor document modification
...
* the "modifyingCurrentDocument" now handles
all the followup actions necessary after
modifying the current document,
such as updating the title bar
2020-09-05 02:56:59 +02:00
sheaf
264fa8dff0
dynamic file tab close button behaviour
2020-09-04 22:51:47 +02:00
sheaf
86729cb462
update title and file tab upon change, close
2020-09-04 20:54:48 +02:00
sheaf
341a8ed0ca
closing documents / removing file tabs
2020-09-03 05:57:08 +02:00
sheaf
5f3bbc891a
add saving/loading
2020-09-03 00:53:08 +02:00
sheaf
db4115c634
hook up menu to actions, + some refactors
2020-09-02 22:49:50 +02:00
sheaf
919acf4928
add accelerator labels to menu items
2020-09-02 15:58:00 +02:00
sheaf
7033578e20
refactor: separation of event handling and actions
2020-09-02 04:52:08 +02:00
sheaf
101d9515c0
update file tabs dynamically
2020-09-01 21:56:59 +02:00
sheaf
8a6b4f5391
encode/decode documents to JSON using waargonaut
2020-08-31 22:28:30 +02:00
sheaf
9c5f8b1198
use correct applicative operation for brush lerp
2020-08-31 01:59:14 +02:00
sheaf
9e73da9fff
implement selection & drag-move in brush mode
2020-08-29 22:19:51 +02:00
sheaf
dfa446254a
adjust what is rendered in different modes
2020-08-29 20:50:02 +02:00
sheaf
9bde44ed42
fix brush stroke point order for open brush path
...
* also: add some preset brushes
2020-08-29 19:41:07 +02:00
sheaf
62bb1451c5
curve fitting: implement recursive subdivision
2020-08-29 18:26:11 +02:00
sheaf
d4561ad549
use the correct tangent vector for stroke joins
2020-08-29 16:34:51 +02:00
sheaf
3916fe2656
compute and render brush stroke outlines
2020-08-29 03:03:29 +02:00
sheaf
b3941a2834
use hmatrix for least squares solving
...
* this fixes the convergence problems of cubic Bézier curve fitting
2020-08-26 00:41:34 +02:00
sheaf
f16ac3fa93
fitting a cubic Bézier to a sequence of points
...
* WIP: current code exhibits convergence issues / instability
2020-08-24 10:55:39 +02:00
sheaf
86a1426136
start implementing brush mode
2020-08-20 03:57:26 +02:00
sheaf
e8c77befd6
split out stroke code to library
2020-08-19 23:34:43 +02:00
sheaf
e044b1b06c
stroking: compute offset given tangent vector
2020-08-19 17:41:15 +02:00
sheaf
107b27ebca
implement deletion of selection
2020-08-19 05:28:47 +02:00
sheaf
0f2eddab80
ctrl while drawing moves previous control point
2020-08-17 01:02:34 +02:00
sheaf
596821222f
implement drawing with the pen tool
2020-08-17 00:09:16 +02:00
sheaf
38c4e9fa6c
add mouse drag-move operation
2020-08-15 23:49:14 +02:00
sheaf
10dccd1dad
update selected objects on selection event
2020-08-15 19:11:52 +02:00
sheaf
91e1431306
add selection UI
2020-08-14 00:47:10 +02:00
sheaf
8d50c92ca9
highlight points for hover/selection
2020-08-13 19:58:54 +02:00
sheaf
ae0ac23910
draw Bézier curves and connecting lines
2020-08-12 23:23:25 +02:00
sheaf
2bd6847e78
add root solving code, coalesce event handling
2020-08-12 22:43:47 +02:00
sheaf
d74d4fd5cc
use fixed number of digits in infobar
2020-08-11 12:22:56 +02:00
sheaf
07f9981c41
update infobar, mouse focus zoom, module refactor
2020-08-11 00:07:09 +02:00
sheaf
9fc7b8acb3
basic rendering, mousewheel scrolling
2020-08-10 16:38:27 +02:00
sheaf
62ea168667
add info bar
2020-08-08 05:33:35 +02:00
sheaf
c9394cc23f
toolbar improvements, better colours
2020-08-08 00:41:08 +02:00
sheaf
cc96802f8e
window icons, tool bar
2020-08-07 21:39:24 +02:00
sheaf
9bc8e096c9
file tab close buttons
2020-08-06 05:09:52 +02:00
sheaf
4e41b5c294
center title, paned viewport
2020-08-05 23:30:36 +02:00
sheaf
f224c6b738
add MenuBar
2020-08-05 22:23:16 +02:00
sheaf
c9e702e660
WIP
2020-08-04 08:43:25 +02:00