Class NFD

java.lang.Object
overrungl.nfd.NFD

public final class NFD extends Object

Native File Dialog Extended binding.

See the source repository for basic usages.

Important

NFD uses UTF-16 on Windows. You should use NFD_AllocString and NFD_NativeString instead of the MemoryUtil version.

Since:
0.1.0
Author:
squid233
  • Field Details

    • NFD_INTERFACE_VERSION

      public static final int NFD_INTERFACE_VERSION
      See Also:
    • NFD_ERROR

      public static final int NFD_ERROR
      See Also:
    • NFD_OKAY

      public static final int NFD_OKAY
      See Also:
    • NFD_CANCEL

      public static final int NFD_CANCEL
      See Also:
    • NFD_WINDOW_HANDLE_TYPE_UNSET

      public static final int NFD_WINDOW_HANDLE_TYPE_UNSET
      See Also:
    • NFD_WINDOW_HANDLE_TYPE_WINDOWS

      public static final int NFD_WINDOW_HANDLE_TYPE_WINDOWS
      See Also:
    • NFD_WINDOW_HANDLE_TYPE_COCOA

      public static final int NFD_WINDOW_HANDLE_TYPE_COCOA
      See Also:
    • NFD_WINDOW_HANDLE_TYPE_X11

      public static final int NFD_WINDOW_HANDLE_TYPE_X11
      See Also:
    • NFD_CHARSET

      public static final Charset NFD_CHARSET
      On Windows, this is UTF-16 little-endian; on others, this is UTF-8
    • nfdnchar_t

      public static final MemoryLayout nfdnchar_t
      On Windows, this is wchar_t; on others, this is byte
    • nfdpathsetsize_t

      public static final MemoryLayout nfdpathsetsize_t
      On macOS, this is C long; on Windows and others, this is int
  • Method Details

    • NFD_FreePath

      public static void NFD_FreePath(MemorySegment filePath)
      void NFD_FreePathN(nfdnchar_t* filePath);
      
    • NFD_Init

      public static int NFD_Init()
      (int) nfdresult_t NFD_Init();
      
    • NFD_Quit

      public static void NFD_Quit()
      void NFD_Quit();
      
    • NFD_OpenDialog

      public static int NFD_OpenDialog(MemorySegment outPath, MemorySegment filterList, int filterCount, MemorySegment defaultPath)
      (int) nfdresult_t NFD_OpenDialogN(nfdnchar_t** outPath, const nfdnfilteritem_t* filterList, (unsigned int) nfdfiltersize_t filterCount, const nfdnchar_t* defaultPath);
      
    • NFD_OpenDialog_With_Impl

      public static int NFD_OpenDialog_With_Impl(long version, MemorySegment outPath, MemorySegment args)
      (int) nfdresult_t NFD_OpenDialogN_With_Impl((size_t) nfdversion_t version, nfdnchar_t** outPath, const nfdopendialognargs_t* args);
      
    • NFD_OpenDialog_With

      public static int NFD_OpenDialog_With(MemorySegment outPath, MemorySegment args)
      (int) nfdresult_t NFD_OpenDialog_With(nfdnchar_t** outPath, const nfdopendialognargs_t* args);
      
    • NFD_OpenDialogMultiple

      public static int NFD_OpenDialogMultiple(MemorySegment outPaths, MemorySegment filterList, int filterCount, MemorySegment defaultPath)
      (int) nfdresult_t NFD_OpenDialogMultipleN(const nfdpathset_t** outPaths, const nfdnfilteritem_t* filterList, (unsigned int) nfdfiltersize_t filterCount, const nfdnchar_t* defaultPath);
      
    • NFD_OpenDialogMultiple_With_Impl

      public static int NFD_OpenDialogMultiple_With_Impl(long version, MemorySegment outPaths, MemorySegment args)
      (int) nfdresult_t NFD_OpenDialogMultipleN_With_Impl((size_t) nfdversion_t version, const nfdpathset_t** outPaths, const nfdopendialognargs_t* args);
      
    • NFD_OpenDialogMultiple_With

      public static int NFD_OpenDialogMultiple_With(MemorySegment outPaths, MemorySegment args)
      (int) nfdresult_t NFD_OpenDialogMultiple_With(const nfdpathset_t** outPaths, const nfdopendialognargs_t* args);
      
    • NFD_SaveDialog

      public static int NFD_SaveDialog(MemorySegment outPath, MemorySegment filterList, int filterCount, MemorySegment defaultPath, MemorySegment defaultName)
      (int) nfdresult_t NFD_SaveDialogN(nfdnchar_t** outPath, const nfdnfilteritem_t* filterList, (unsigned int) nfdfiltersize_t filterCount, const nfdnchar_t* defaultPath, const nfdnchar_t* defaultName);
      
    • NFD_SaveDialog_With_Impl

      public static int NFD_SaveDialog_With_Impl(long version, MemorySegment outPath, MemorySegment args)
      (int) nfdresult_t NFD_SaveDialogN_With_Impl((size_t) nfdversion_t version, nfdnchar_t** outPath, const nfdsavedialognargs_t* args);
      
    • NFD_SaveDialog_With

      public static int NFD_SaveDialog_With(MemorySegment outPath, MemorySegment args)
      (int) nfdresult_t NFD_SaveDialog_With(nfdnchar_t** outPath, const nfdsavedialognargs_t* args);
      
    • NFD_PickFolder

      public static int NFD_PickFolder(MemorySegment outPath, MemorySegment defaultPath)
      (int) nfdresult_t NFD_PickFolderN(nfdnchar_t** outPath, const nfdnchar_t* defaultPath);
      
    • NFD_PickFolder_With_Impl

      public static int NFD_PickFolder_With_Impl(long version, MemorySegment outPath, MemorySegment args)
      (int) nfdresult_t NFD_PickFolderN_With_Impl((size_t) nfdversion_t version, nfdnchar_t** outPath, const nfdpickfoldernargs_t* args);
      
    • NFD_PickFolder_With

      public static int NFD_PickFolder_With(MemorySegment outPath, MemorySegment args)
      (int) nfdresult_t NFD_PickFolder_With(nfdnchar_t** outPath, const nfdpickfoldernargs_t* args);
      
    • NFD_PickFolderMultiple

      public static int NFD_PickFolderMultiple(MemorySegment outPaths, MemorySegment defaultPath)
      (int) nfdresult_t NFD_PickFolderMultipleN(const nfdpathset_t** outPaths, const nfdnchar_t* defaultPath);
      
    • NFD_PickFolderMultiple_With_Impl

      public static int NFD_PickFolderMultiple_With_Impl(long version, MemorySegment outPaths, MemorySegment args)
      (int) nfdresult_t NFD_PickFolderMultipleN_With_Impl((size_t) nfdversion_t version, const nfdpathset_t** outPaths, const nfdpickfoldernargs_t* args);
      
    • NFD_PickFolderMultiple_With

      public static int NFD_PickFolderMultiple_With(MemorySegment outPaths, MemorySegment args)
      (int) nfdresult_t NFD_PickFolderMultiple_With(const nfdpathset_t** outPaths, const nfdpickfoldernargs_t* args);
      
    • NFD_GetError

      public static MemorySegment NFD_GetError()
      const char* NFD_GetError();
      
    • NFD_ClearError

      public static void NFD_ClearError()
      void NFD_ClearError();
      
    • NFD_PathSet_GetCount

      public static int NFD_PathSet_GetCount(MemorySegment pathSet, MemorySegment count)
      (int) nfdresult_t NFD_PathSet_GetCount(const nfdpathset_t* pathSet, nfdpathsetsize_t* count);
      
    • NFD_PathSet_GetPath

      public static int NFD_PathSet_GetPath(MemorySegment pathSet, long index, MemorySegment outPath)
      (int) nfdresult_t NFD_PathSet_GetPathN(const nfdpathset_t* pathSet, (size_t) nfdpathsetsize_t index, nfdnchar_t** outPath);
      
    • NFD_PathSet_FreePath

      public static void NFD_PathSet_FreePath(MemorySegment filePath)
      void NFD_PathSet_FreePathN(const nfdnchar_t* filePath);
      
    • NFD_PathSet_GetEnum

      public static int NFD_PathSet_GetEnum(MemorySegment pathSet, MemorySegment outEnumerator)
      (int) nfdresult_t NFD_PathSet_GetEnum(const nfdpathset_t* pathSet, nfdpathsetenum_t* outEnumerator);
      
    • NFD_PathSet_FreeEnum

      public static void NFD_PathSet_FreeEnum(MemorySegment enumerator)
      void NFD_PathSet_FreeEnum(nfdpathsetenum_t* enumerator);
      
    • NFD_PathSet_EnumNext

      public static int NFD_PathSet_EnumNext(MemorySegment enumerator, MemorySegment outPath)
      (int) nfdresult_t NFD_PathSet_EnumNextN(nfdpathsetenum_t* enumerator, nfdnchar_t** outPath);
      
    • NFD_PathSet_Free

      public static void NFD_PathSet_Free(MemorySegment pathSet)
      void NFD_PathSet_Free(const nfdpathset_t* pathSet);
      
    • NFD_AllocString

      public static MemorySegment NFD_AllocString(SegmentAllocator allocator, String string)
    • NFD_NativeString

      public static String NFD_NativeString(MemorySegment segment)