Skip to content

Commit

Permalink
more config file things
Browse files Browse the repository at this point in the history
  • Loading branch information
zunda-arrow committed Jun 1, 2024
1 parent 1499a17 commit 6d7687e
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
2 changes: 1 addition & 1 deletion constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const X11StartupCommand = "exec /bin/bash --login /etc/aporia/.scripts/startx.sh
var ShutdownCommand = []string{"/bin/bash", "-c", "shutdown now"}
var RebootCommand = []string{"/bin/bash", "-c", "reboot"}

const BoxWidth = 90
const BoxWidth = 35

// Ascii art used when there is no config
const DefaultAsciiArt = `Check the docs on how to add an ascii art!`
Expand Down
11 changes: 11 additions & 0 deletions examples/config
Original file line number Diff line number Diff line change
@@ -1,2 +1,13 @@
# Ascii is the name of the ascii file to use
ascii = sata_andagi

# The size of the box in the top left. Warning: values lower than 35 will not display properly.
box_width = 50

# The shutdown and reboot commands to use
shutdown_command = /bin/bash -c shutdown now
reboot_command = /bin/bash -c reboot

# The paths to search for desktop files
xsessions_path = /usr/share/xsessions
wayland_sessions_path = /usr/share/wayland-sessions
2 changes: 1 addition & 1 deletion tui/fields.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ type picker struct {
func (self *picker) draw(boxSize int) (string, int) {
sessionName := self.options[self.selected]

sideSpacing := (boxSize / 2 - 15)
sideSpacing := (boxSize / 2 - 15) / 2
leftover := boxSize - 4 - (boxSize / 2 - 15)

spacingBefore := (leftover - len(sessionName)) / 2
Expand Down

0 comments on commit 6d7687e

Please sign in to comment.