【发布时间】:2012-04-01 13:05:38
【问题描述】:
当我使用文件选择器选择文件时,我正在尝试获取文件的名称。
我做到了
gchar *name = gtk_file_chooser_get_filename(open_dialog);
但这将返回 /home/user/Desktop/test.file 而不是我想要的 test.file。
有什么方法可以获取文件名而不是它的uri吗?
【问题讨论】:
-
为什么不直接从该路径中提取文件名?
标签: c gtk filechooser