Skip to content

Commit

Permalink
update view tags to display in marbles
Browse files Browse the repository at this point in the history
  • Loading branch information
kkoreilly committed Sep 17, 2024
1 parent 24f47a2 commit 4da7d86
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
16 changes: 8 additions & 8 deletions marbles/graph.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,28 +84,28 @@ type Params struct { //types:add
MarbleStartY Expr

// Starting horizontal velocity of the marbles
StartVelocityY Param `view:"inline" label:"Starting velocity y"`
StartVelocityY Param `display:"inline" label:"Starting velocity y"`

// Starting vertical velocity of the marbles
StartVelocityX Param `view:"inline" label:"Starting velocity x"`
StartVelocityX Param `display:"inline" label:"Starting velocity x"`

// how fast to move along velocity vector -- lower = smoother, more slow-mo
UpdateRate Param `view:"inline"`
UpdateRate Param `display:"inline"`

// how fast time increases
TimeStep Param `view:"inline"`
TimeStep Param `display:"inline"`

// how fast it accelerates down
YForce Param `view:"inline" label:"Y force (Gravity)"`
YForce Param `display:"inline" label:"Y force (Gravity)"`

// how fast the marbles move side to side without collisions, set to 0 for no movement
XForce Param `view:"inline" label:"X force (Wind)"`
XForce Param `display:"inline" label:"X force (Wind)"`

// the center point of the graph, x
CenterX Param `view:"inline" label:"Graph center x"`
CenterX Param `display:"inline" label:"Graph center x"`

// the center point of the graph, y
CenterY Param `view:"inline" label:"Graph center y"`
CenterY Param `display:"inline" label:"Graph center y"`

TrackingSettings TrackingSettings
}
Expand Down
6 changes: 3 additions & 3 deletions marbles/settings.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ import (

// Settings are the settings the app has
type Settings struct {
LineDefaults LineDefaults `view:"no-inline" label:"Line Defaults"`
LineDefaults LineDefaults `display:"no-inline" label:"Line Defaults"`

GraphDefaults Params `view:"no-inline" label:"Graph Param Defaults"`
GraphDefaults Params `display:"no-inline" label:"Graph Param Defaults"`

MarbleSettings MarbleSettings `view:"inline" label:"Marble Settings"`
MarbleSettings MarbleSettings `display:"inline" label:"Marble Settings"`

GraphSize int `label:"Graph Size" min:"100" max:"800"`

Expand Down

0 comments on commit 4da7d86

Please sign in to comment.