Commit Graph

12 Commits

Author SHA1 Message Date
Kartik K. Agaram 68adcf8408 no menu bar for file picker 2023-06-21 22:30:25 -07:00
Kartik K. Agaram c8cd9bb6b6 start rendering file picker on the surface as well
This will make things more consistent in the long term, but I realize
one major cost: our button abstraction doesn't work well with luaML and
compute_layout. So we need something to replace it.
2023-06-21 22:28:56 -07:00
Kartik K. Agaram 37d5358290 start rendering the initialized thread
This required a little more restructuring of Global_state. It's not flat
now, it's hierarchical again, but in a different way.

after commit 3d89b8eb9d:
  post
    \- reply A
        \- reply B
    \- reply C

after commit f9f7dab9b7:
  post
  reply A
  reply B
  reply C

after this commit:
  row
    \- col
        \- indent 0
        \- post
    \- col
        \- indent 1
        \- reply A
    \- col
        \- indent 2
        \- reply B
    \- col
        \- indent 1
        \- reply C

The indents are just invisible rectangles of different widths with 0
height.

One change I had to make was to initialize_editor. Neither luaML and
driver load lines from disk, but that's arguably the common scenario to
support.
2023-06-20 20:10:10 -07:00
Kartik K. Agaram f9f7dab9b7 restructure Global_state
Instead of a tree of items, we now have a flat list. Each item knows its
depth. This structure is closer to what luaML's compute_layout needs.

For any future hierarchical functionality, each item still knows its
parent and replies as ids inside the metadata field.

Next step: redo A for this app. compute_layout should stay fairly
timeless across forks of luaML.

Pace layers for apps built on the box model:
  A
  B
  ...
  F (I think of on.draw as F)

A runs least frequently, F runs on every frame.

In this app, the plan is:
  * initialize_thread will load items inside Global_state
  * A will convert items into a relatively stable box model of rows,
    columns and text editors in Surface, using compute_layout as a
    helper.
  * B will recompute some aspects of Surface as the viewport moves.

Anything that changes the height of any box needs to rerun A. Anything
that moves the viewport reruns B.
2023-06-20 17:13:01 -07:00
Kartik K. Agaram fd5ca6f3f8 load in-memory data for a thread
Nothing displayed yet. I need to convert threads to Surface nodes.
2023-06-18 20:10:20 -07:00
Kartik K. Agaram 3917fa9d94 get rid of animation and editor movement
Editors also have some padding within their borders.
2023-06-18 13:04:18 -07:00
Kartik K. Agaram 5b91bc288c new fork: pothi
Second attempt based on driver.love
2023-06-18 11:16:58 -07:00
Kartik K. Agaram 070ac4a01b indent 2023-06-10 12:18:29 -07:00
Kartik K. Agaram 2d5abe140b make order of files consistent with upstream
Luckily I only had a chance to mess this up in one fork.

And I don't need to actually make any changes because my definitions are
order-independent.
2023-04-22 18:50:18 -07:00
Kartik K. Agaram 6bf029748c Merge luaML.love 2023-04-16 11:35:42 -07:00
Kartik K. Agaram b138f1ff9b Merge template-live-editor 2023-04-16 11:30:56 -07:00
Kartik K. Agaram 4f62ea1f8c render hierarchies of rows and columns of text
We can't edit any text yet.
2022-12-17 12:41:00 -08:00