Lagrange [work/v1.13]

Terminal: Input widget behavior; upload dialog width

=> 091a5b4d8821f42cc4177dd5174dd60b3e46f11c

diff --git a/src/ui/keys.h b/src/ui/keys.h
index ff8b0913..205bd0d8 100644
--- a/src/ui/keys.h
+++ b/src/ui/keys.h
@@ -50,8 +50,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */
 #   define rightSidebar_KeyShortcut     SDLK_p,             KMOD_SHIFT
 #   define menuBar_KeyShortcut          '?',                0
 #   define leftSidebarTab_KeyModifier   0
-#   define byWord_KeyModifier           KMOD_ALT
-#   define byLine_KeyModifier           KMOD_PRIMARY
+#   define byWord_KeyModifier           KMOD_CTRL
+#   define byLine_KeyModifier           KMOD_ALT
 #   define rightSidebarTab_KeyModifier  KMOD_ALT
 #elif defined (iPlatformApple)
 #   define pageInfo_KeyShortcut         SDLK_i, KMOD_PRIMARY
diff --git a/src/ui/uploadwidget.c b/src/ui/uploadwidget.c
index 596236ac..8114d7db 100644
--- a/src/ui/uploadwidget.c
+++ b/src/ui/uploadwidget.c
@@ -234,6 +234,7 @@ void init_UploadWidget(iUploadWidget *d) {
 //        addChildFlags_Widget(title, iClob(menu), frameless_WidgetFlag | moveToParentRightEdge_WidgetFlag);
     }
     else {
+        const float aspect = isTerminal_App() ? 0.6f : 1.0f;
         useSheetStyle_Widget(w);
         setFlags_Widget(w, overflowScrollable_WidgetFlag, iFalse);
         addDialogTitle_Widget(w, "${heading.upload}", NULL);
@@ -265,7 +266,7 @@ void init_UploadWidget(iUploadWidget *d) {
             setFlags_Widget(page, arrangeSize_WidgetFlag, iTrue);
             d->input = new_InputWidget(0);
             setId_Widget(as_Widget(d->input), "upload.text");
-            setFixedSize_Widget(as_Widget(d->input), init_I2(120 * gap_UI * aspect_UI, -1));
+            setFixedSize_Widget(as_Widget(d->input), init_I2(120 * gap_UI * aspect, -1));
             addChild_Widget(page, iClob(d->input));
             appendFramelessTabPage_Widget(tabs, iClob(page), "${heading.upload.text}", '1', 0);
         }
@@ -277,7 +278,7 @@ void init_UploadWidget(iUploadWidget *d) {
             addChildFlags_Widget(headings, iClob(new_LabelWidget("${upload.file.size}", NULL)), frameless_WidgetFlag);
             d->fileSizeLabel = addChildFlags_Widget(values, iClob(new_LabelWidget("\u2014", NULL)), frameless_WidgetFlag);
             d->mime = new_InputWidget(0);
-            setFixedSize_Widget(as_Widget(d->mime), init_I2(70 * gap_UI * aspect_UI, -1));
+            setFixedSize_Widget(as_Widget(d->mime), init_I2(70 * gap_UI * aspect, -1));
             addTwoColumnDialogInputField_Widget(headings, values, "${upload.mime}", "upload.mime", iClob(d->mime));
         }
         /* Identity and Token. */ {
@@ -297,7 +298,7 @@ void init_UploadWidget(iUploadWidget *d) {
             d->token = addTwoColumnDialogInputField_Widget(
                 headings, values, "${upload.token}", "upload.token", iClob(new_InputWidget(0)));
             setHint_InputWidget(d->token, "${hint.upload.token}");
-            setFixedSize_Widget(as_Widget(d->token), init_I2(50 * gap_UI * aspect_UI, -1));
+            setFixedSize_Widget(as_Widget(d->token), init_I2(50 * gap_UI * aspect, -1));
             addChild_Widget(w, iClob(page));
         }
         /* Buttons. */ {
Proxy Information
Original URL
gemini://git.skyjake.fi/lagrange/work%2Fv1.13/cdiff/091a5b4d8821f42cc4177dd5174dd60b3e46f11c
Status Code
Success (20)
Meta
text/gemini; charset=utf-8
Capsule Response Time
50.909785 milliseconds
Gemini-to-HTML Time
0.284296 milliseconds

This content has been proxied by September (ba2dc).