From 508a86325e732e3bba32a849f29399187c97df0a Mon Sep 17 00:00:00 2001 From: Jaidyn Ann <10477760+JadedCtrl@users.noreply.github.com> Date: Mon, 5 Feb 2024 15:50:59 -0600 Subject: [PATCH] Mere formatting tweaks --- contact.scm | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/contact.scm b/contact.scm index 68612a1..d93f0de 100644 --- a/contact.scm +++ b/contact.scm @@ -1,4 +1,4 @@ -;; Copyright © 2023, Jaidyn Ann +;; Copyright © 2024 Jaidyn Ann ;; ;; This program is free software: you can redistribute it and/or ;; modify it under the terms of the GNU General Public License as @@ -20,8 +20,8 @@ ;; Start & run the application. (define (init) - (let ([qt-app (qt:init)] - [qt-win (create-window)]) + (let [(qt-app (qt:init)) + (qt-win (create-window))] (init-window qt-win) (qt:run))) @@ -55,32 +55,32 @@ ;; Connect callback functions to menubar items. (define (menubar-callbacks window) - (let* ([file→exit (qt:find window "actionQuit")] - [file→save (qt:find window "actionSave")]) + (let* [(menu-file-exit (qt:find window "actionQuit")) + (menu-file-save (qt:find window "actionSave"))] ;; We connect to https://doc.qt.io/qt-6/qaction.html#triggered - (if file→exit + (if menu-file-exit (qt:connect - file→exit "triggered()" + menu-file-exit "triggered()" (qt:receiver exit))) - (if file→save + (if menu-file-save (qt:connect - file→save "triggered()" + menu-file-save "triggered()" (qt:receiver (lambda () - (qt:message "Saving is not implemented." "Saving"))))))) + (qt:message "Saving is not implemented."))))))) ;; Connect a text-printing callback to each textbox. (define (textbox-callbacks window) - (let* ([property-names - '("address" "city" "company" "county" "eMail" "fax" + (let* [(property-names + '("address" "city" "company" "country" "eMail" "fax" "homePhone" "name" "nickname" "state" "url" - "workPhone" "zip")] - [textboxes + "workPhone" "zip")) + (textboxes ;; The texbox widgets are all named like “countryLineEdit”. (map (lambda (property) (qt:find window (conc property "LineEdit"))) - property-names)]) + property-names))] ;; Cycle through each textbox, connecting them to a callback that prints ;; their contents each time you type in text. (map (lambda (textbox) @@ -92,9 +92,9 @@ (qt:connect textbox "textChanged(QString)" (qt:receiver (lambda () - (let ([file→save (qt:find window "actionSave")]) - (if file→save - (set! (qt:property file→save "enabled") #t))) + (let [(menu-file-save (qt:find window "actionSave"))] + (if menu-file-save + (set! (qt:property menu-file-save "enabled") #t))) (print (qt:property textbox "text"))))))) textboxes)))