added urrl in prompt

This commit is contained in:
Paul Wilde 2022-07-17 19:58:28 +01:00
parent 1fa63c2839
commit d88e57f367
17 changed files with 24 additions and 23 deletions

View file

@ -88,7 +88,7 @@ proc getDesign(charge: int, state: bool): (string, string, string, string, strin
proc getOutput(charge: int, state: bool): Info =
let (html_text,main_text,col,bg_col,highlight_col) = get_design(charge, state)
var data = newInfo("Battery")
var data = newInfo("Batturry")
data.full_text = main_text
data.selected_bg = highlight_col
data.selected_fg = col # may just want `black` here

View file

@ -59,7 +59,7 @@ proc getBrightness*(run_once: bool = false) =
let pcnt = (current/limit)*100
if pcnt != last_pcnt:
let text = getDesign(pcnt)
var data = newInfo("Brightness")
var data = newInfo("Brightnurrs")
data.full_text = text
data.selected_bg = default_fg
data.selected_fg = default_bg

View file

@ -1,10 +1,11 @@
import ../../globurrl
import std/[osproc,strutils,sequtils]
#using qalc as it has a lot of nice inbuilt features
#
# using qalc as it has a lot of nice inbuilt features
# may be nice to make it totally non-dependant on other things though
proc doCalculation(calc: string) =
var info = newInfo("Calculator")
var info = newInfo("Calculaturr")
let ans_cmd_terse = "echo \"" & calc & "\" | qalc +u8 -terse -color=never | awk '!/^>/ && !/^$/ {gsub(/^[ \\t]+|[ \\t]+$/, \"\", $0); print}'"
let ans_cmd_full = "echo \"" & calc & "\" | qalc +u8 -color=never | awk '!/^>/ && !/^$/ {gsub(/^[ \\t]+|[ \\t]+$/, \"\", $0); print}'"
var ans_full = execCmdEx(ans_cmd_full)
@ -24,7 +25,7 @@ proc doCalculation(calc: string) =
doCalculation(cmd)
proc main() =
var info = newInfo("Calculator")
var info = newInfo("Calculaturr")
let args = @["exit"]
let cmd = outputData(info, args)
if cmd != "":

View file

@ -8,7 +8,7 @@ const cal_pos_x = "20"
const cal_pos_y = "20"
proc getObject(date: string): Info =
var data = newInfo("Date")
var data = newInfo("Calendurr")
data.full_text = date
data.border = default_bg
data.selected_bg = default_bg

View file

@ -3,7 +3,7 @@ import lib/emurrjilist
import std/[re]
proc main() =
var info = newInfo("Emoji Picker")
var info = newInfo("Emurrji")
var args = getEmoji()
args.add("exit")
let output = outputData(info,args)

View file

@ -73,7 +73,7 @@ proc getMinute(min: int): string =
return "error"
proc getObject(time: string): Info =
var data = newInfo("Fuzzy Time")
var data = newInfo("Furry Time")
data.full_text = time
data.selected_bg = default_bg
data.selected_fg = default_fg

View file

@ -185,7 +185,7 @@ proc getWorkspaces(): seq[Workspace] =
proc showWorkspaces() =
my_workspaces = @[]
getTree()
var info = newInfo("Workspaces")
var info = newInfo("Wurrkspaces")
var args: seq[string] = @[]
for ws in my_workspaces:
args.add(ws.display_string)

View file

@ -28,7 +28,7 @@ proc getConnState(nic: string): (string, string) =
return (ip, state)
proc getObject(): Info =
var data = newInfo("IP")
var data = newInfo("Netwurrk")
data.selected_bg = default_bg
data.selected_fg = default_fg
# i3bar stuff

View file

@ -64,7 +64,7 @@ proc writeNote(note: Note, is_new: bool = false) =
echo "write_note, Unable to write note : ", note.id, " : ", getCurrentExceptionMsg()
proc getNotes(): (Info, seq[string]) =
var info = newInfo("Notes")
var info = newInfo("Noteurr")
info.selected_bg = default_bg
info.selected_fg = default_fg
let notes = getNoteStrings()
@ -115,7 +115,7 @@ proc replaceNote(new_text: string, old_text: string) =
return
proc displayOptionMenu(option: string) =
var select = newInfo("Note")
var select = newInfo("Noteurr")
select.selected_bg = default_bg
select.selected_fg = default_fg
let note_choices = @["rm","back"]

View file

@ -44,7 +44,7 @@ proc getObject(ping: float): Info =
else:
state = 9
var data = newInfo("Ping Clock")
var data = newInfo("Ping Clurrk")
data.full_text = text
# i3bar stuff
data.color = default_fg

View file

@ -39,7 +39,7 @@ proc startRemmina(conn: string) =
discard execCmd("remmina -c " & quote(session))
proc selectRemmina(conn: string) =
var info = newInfo("Remmina : " & conn)
var info = newInfo("Remmina Choosurr : " & conn)
let args = @["connect", "edit", "back"]
let output = outputData(info,args)
if output in args:
@ -56,7 +56,7 @@ proc selectRemmina(conn: string) =
proc main() =
var info = newInfo("Remmina")
var info = newInfo("Remmina Choosurr")
var args: seq[string] = getRemminaFiles()
args.add("new")
args.add("exit")

View file

@ -40,7 +40,7 @@ proc openFile(filename: string) =
return
proc showScreenshotSaveSel(filename: string) =
let info = newInfo("Save Screenshot")
let info = newInfo("Screenshurrt")
let args = @["clipboard", "save", "open", "---", "exit"]
let choice = outputData(info,args)
if choice == "---":
@ -58,7 +58,7 @@ proc showScreenshotSaveSel(filename: string) =
return
proc showScreenshotTypeSel() =
let info = newInfo("Screenshot type")
let info = newInfo("Screenshurrt type")
let args = concat(TYPES,@["---","exit"])
let choice = outputData(info,args)
if choice in TYPES:

View file

@ -49,7 +49,7 @@ proc getObject(temp: int): Info =
icon = ""
let text = "<span foreground='" & bg_col & "'>" & icon & "</span> " & $temp & "°C"
let main_text = icon & " " & $temp & "°C"
var data = newInfo("Temperature")
var data = newInfo("Temperaturr")
data.full_text = main_text
data.selected_bg = bg_col
data.selected_fg = fg_col

View file

@ -71,7 +71,7 @@ proc getDesign(tides: seq[Tide]): Info =
for tide in tides:
let str = icon & tide.State[0] & " " & tide.Time & " " & tide.Height
my_tides.add(str)
var data = newInfo("Tides")
var data = newInfo("Tideurrl")
data.border = black
data.args = my_tides
return data

View file

@ -92,7 +92,7 @@ proc detectLanguage(str: string) =
return
proc main(messages:varargs[string] = @[]) =
var info = newInfo("Translate")
var info = newInfo("Translaturr")
info.selected_bg = green
var args: seq[string] = @[]
for msg in messages:

View file

@ -66,7 +66,7 @@ proc volumeMute() =
proc getVolume*(run_once: bool = false) =
let vol = getCurrentVolume()
let (text, main_text) = getDesign(vol)
var data = newInfo("Volume")
var data = newInfo("Volurrme")
data.full_text = main_text
data.selected_bg = default_bg
data.selected_fg = default_fg

View file

@ -27,7 +27,7 @@ proc getWifi(nic: string): (string, string) =
return (ssid, quality)
proc getObject(): Info =
var data = newInfo("WiFi")
var data = newInfo("Wirelurrs")
data.border = purple
data.selected_bg = default_bg
data.selected_fg = default_fg