From 24781de8bedb3bf4d12d7ec1d0307842e59a3f94 Mon Sep 17 00:00:00 2001 From: Jedidiah Barber Date: Tue, 10 Dec 2024 20:47:53 +1300 Subject: Binding for filename.H added --- doc/filename.html | 304 +++++++++++++++++++++++++++++++++++++++++++++++ doc/fl_file_chooser.html | 9 +- doc/index.html | 2 + 3 files changed, 312 insertions(+), 3 deletions(-) create mode 100644 doc/filename.html (limited to 'doc') diff --git a/doc/filename.html b/doc/filename.html new file mode 100644 index 0000000..a922359 --- /dev/null +++ b/doc/filename.html @@ -0,0 +1,304 @@ + + + + + + Filename Binding Map + + + + + + +

Filename Binding Map

+ + +Back to Index + + + + + + + + + + +
Package name
filenameFLTK.Filenames
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
Types
char *Path_String
intComparison
Fl_File_Sort_FCompare_Function
struct dirent ***File_List
+ + + + + + + + + + + +
Errors
char * msgOpen_URI_Error
+ + + + + + + + + + + +
Attributes
+#define FL_PATH_MAX 2048
+
+Max_Path_Length : constant Natural;
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Functions and Procedures
+int fl_alphasort(struct dirent **, struct dirent **);
+
+function Alpha_Sort
+       (A, B : in String)
+    return Comparison;
+
+int fl_casealphasort(struct dirent **, struct dirent **);
+
+function Case_Alpha_Sort
+       (A, B : in String)
+    return Comparison;
+
+int fl_casenumericsort(struct dirent **, struct dirent **);
+
+function Case_Numeric_Sort
+       (A, B : in String)
+    return Comparison;
+
+void fl_decode_uri(char *uri);
+
+function Decode_URI
+       (URI : in Path_String)
+    return Path_String;
+
+int fl_filename_absolute(char *to, int tolen, const char *from);
+
+function Absolute
+       (Name : in Path_String)
+    return Path_String;
+
+function Absolute
+       (Name    : in     Path_String;
+        Changed :    out Boolean)
+    return Path_String;
+
+int fl_filename_expand(char *to, int tolen, const char *from);
+
+function Expand
+       (Name : in Path_String)
+    return Path_String;
+
+function Expand
+       (Name    : in     Path_String;
+        Changed :    out Boolean)
+    return Path_String;
+
+const char * fl_filename_ext(const char *buf);
+
+function Extension
+       (Name : in Path_String)
+    return Path_String;
+
+void fl_filename_free_list(struct dirent ***l, int n);
+
Automatically called when a File_List goes out of scope.
+int fl_filename_isdir(const char *name);
+
+function Is_Directory
+       (Name : in Path_String)
+    return Boolean;
+
+int fl_filename_list(const char *d, struct dirent ***l,
+    Fl_File_Sort_F *s=fl_numericsort);
+
+function Get_Listing
+       (Name : in Path_String;
+        Sort : in not null Compare_Function :=
+            Numeric_Sort'Access)
+    return File_List;
+
Tracking of the return value of fl_filename_list must be done manually.
+function Length
+       (This : in File_List)
+    return Natural;
+
Dereferencing of a dirent struct must be done manually.
+function Item
+       (This  : in File_List;
+        Index : in Positive)
+    return Path_String
+with Pre => Index in 1 .. This.Length;
+
+int fl_filename_match(const char *name, const char *pattern);
+
+function Match
+       (Input, Pattern : in String)
+    return Boolean;
+
+const char * fl_filename_name(const char *filename);
+
+function Base_Name
+       (Name : in Path_String)
+    return Path_String;
+
+int fl_filename_relative(char *to, int tolen, const char *from);
+
+function Relative
+       (Name : in Path_String)
+    return Path_String;
+
+function Relative
+       (Name    : in     Path_String;
+        Changed :    out Boolean)
+    return Path_String;
+
+char * fl_filename_setext(char *to, int tolen, const char *ext);
+
+function Set_Extension
+       (Name   : in Path_String;
+        Suffix : in String)
+    return Path_String;
+
+int fl_numericsort(struct dirent **, struct dirent **);
+
+function Numeric_Sort
+       (A, B : in String)
+    return Comparison;
+
+int fl_open_uri(const char *uri, char *msg, int msglen);
+
+procedure Open_URI
+       (URI : in Path_String);
+
+ + + + + diff --git a/doc/fl_file_chooser.html b/doc/fl_file_chooser.html index f43989d..06dab72 100644 --- a/doc/fl_file_chooser.html +++ b/doc/fl_file_chooser.html @@ -295,7 +295,10 @@ procedure Set_Show_Label
 static Fl_File_Sort_F * sort = fl_numericsort;
 
-TBA +
+Sort_Method : not null FLTK.Filenames.Compare_Function :=
+    FLTK.Filenames.Numeric_Sort'Access;
+
@@ -687,14 +690,14 @@ procedure Set_Chooser_Kind
 void * user_data() const;
 
-  +Not used in public API.
 void user_data(void *d);
 
-  +Not used in public API. diff --git a/doc/index.html b/doc/index.html index 7e78aba..d58e2da 100644 --- a/doc/index.html +++ b/doc/index.html @@ -17,6 +17,7 @@