From 1493ba6872462de3f251cfba7ba5153e642d61b0 Mon Sep 17 00:00:00 2001 From: LHY0125 <3364451258@qq.com> Date: Mon, 16 Mar 2026 17:39:59 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=B7=BB=E5=8A=A0iupcd=E9=93=BE?= =?UTF-8?q?=E6=8E=A5=E5=B9=B6=E8=B0=83=E6=95=B4=E5=88=97=E8=A1=A8=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 在Makefile的LDFLAGS中添加-liupcd库链接,确保编译时正确链接 - 调整主界面中IupFlatList的视觉样式:修改分隔线颜色为深灰,添加白色背景、边框和焦点支持,提升用户体验 --- Makefile | 2 +- src/main.c | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index da3ba87..a8bc6c6 100644 --- a/Makefile +++ b/Makefile @@ -15,7 +15,7 @@ BIN_DIR = bin # -mwindows: Create GUI app (no console) # -DUNICODE -D_UNICODE: Use Wide Character API CFLAGS = -Wall -O2 -I$(INCLUDE_DIR) -I$(LOCAL_INCLUDE_DIR) -D_WIN32 -DUNICODE -D_UNICODE -fexec-charset=UTF-8 -LDFLAGS = -L$(LIB_DIR) -liup -lgdi32 -lcomdlg32 -lcomctl32 -luuid -lole32 -ladvapi32 -mwindows +LDFLAGS = -L$(LIB_DIR) -liup -liupcd -lgdi32 -lcomdlg32 -lcomctl32 -luuid -lole32 -ladvapi32 -mwindows # Source SRC = src/main.c src/utils.c src/registry.c src/callbacks.c diff --git a/src/main.c b/src/main.c index 22a4292..44d476a 100644 --- a/src/main.c +++ b/src/main.c @@ -39,10 +39,13 @@ int main(int argc, char **argv) list_path = IupFlatList(); IupSetAttribute(list_path, "EXPAND", "YES"); IupSetAttribute(list_path, "HLINE", "YES"); - IupSetAttribute(list_path, "HLINECOLOR", "200 200 200"); + IupSetAttribute(list_path, "HLINECOLOR", "100 100 100"); // 灰色 IupSetAttribute(list_path, "ITEMPADDING", "5x5"); + IupSetAttribute(list_path, "BACKCOLOR", "255 255 255"); + IupSetAttribute(list_path, "BORDER", "YES"); + IupSetAttribute(list_path, "CANFOCUS", "YES"); // IupFlatList 不支持 VISIBLELINES,高度由 EXPAND 和布局决定 - + // 创建右侧按钮 btn_new = IupButton("新建(N)", NULL); btn_edit = IupButton("编辑(E)", NULL);