21#define WIN32_NO_STATUS
22#define WIN32_LEAN_AND_MEAN
29static const WCHAR key_recentfiles[] = {
'R',
'e',
'c',
'e',
'n',
't',
' ',
'f',
'i',
'l',
'e',
30 ' ',
'l',
'i',
's',
't',0};
45 static const WCHAR wszProgramKey[] = {
'S',
'o',
'f',
't',
'w',
'a',
'r',
'e',
'\\',
46 'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
47 'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
48 'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
'i',
'o',
'n',
'\\',
49 'A',
'p',
'p',
'l',
'e',
't',
's',
'\\',
50 'W',
'o',
'r',
'd',
'p',
'a',
'd',0};
55 WCHAR backslash[] = {
'\\',0};
141 static const WCHAR dots[] = {
'.',
'.',
'.',0};
153 LPWSTR truncpos1, truncpos2;
161 *(pos_basename-1) = 0;
164 truncpos1 = pos_basename;
165 *(pos_basename-1) =
'\\';
171 *(pos_basename-1) =
'\\';
175 if(*
pos ==
'\\' || *
pos ==
'/')
196 for(
pos = pos_basename;
pos >= truncpos1;
pos--)
198 if(*
pos ==
'\\' || *
pos ==
'/')
209 if(truncpos1 == pos_basename)
211 else if(truncpos1 == truncpos2 || !truncpos2)
227 WCHAR numFormat[] = {
'&',
'%',
'd',
' ',0};
238 mi.dwTypeData = itemText;
298 for(
j = 0;
j <
i;
j++)
300 pFiles[
i-
j] = pFiles[
i-
j-1];
void registry_read_previewpages(HKEY hKey)
void registry_read_pagemargins(HKEY hKey)
void registry_set_previewpages(HKEY hKey)
void registry_set_pagemargins(HKEY hKey)
static const WCHAR var_file[]
int reg_formatindex(WPARAM format)
void registry_set_filelist(LPCWSTR newFile, HWND hMainWnd)
void registry_read_formatopts_all(DWORD barState[], DWORD wordWrap[])
static const WCHAR key_recentfiles[]
void registry_set_formatopts_all(DWORD barState[], DWORD wordWrap[])
static const WCHAR var_wrap[]
static const WCHAR var_barstate0[]
static const WCHAR var_framerect[]
void registry_read_winrect(RECT *rc)
void registry_read_maximized(DWORD *bMaximized)
static void registry_set_formatopts(int index, LPCWSTR key, DWORD barState[], DWORD wordWrap[])
static const WCHAR var_maximized[]
static const WCHAR key_text[]
void registry_read_options(void)
void registry_set_options(HWND hMainWnd)
static void registry_read_formatopts(int index, LPCWSTR key, DWORD barState[], DWORD wordWrap[])
static void format_filelist_filename(LPWSTR file, LPWSTR out)
static LRESULT registry_get_handle(HKEY *hKey, LPDWORD action, LPCWSTR subKey)
static const WCHAR key_settings[]
void registry_read_filelist(HWND hMainWnd)
static const WCHAR key_rtf[]
static const WCHAR key_options[]
static void truncate_path(LPWSTR file, LPWSTR out, LPWSTR pos1, LPWSTR pos2)
LPWSTR file_basename(LPWSTR path)
#define RegCloseKey(hKey)
LONG WINAPI RegCreateKeyExW(_In_ HKEY hKey, _In_ LPCWSTR lpSubKey, _In_ DWORD Reserved, _In_opt_ LPWSTR lpClass, _In_ DWORD dwOptions, _In_ REGSAM samDesired, _In_opt_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, _Out_ PHKEY phkResult, _Out_opt_ LPDWORD lpdwDisposition)
LONG WINAPI RegOpenKeyExW(HKEY hKey, LPCWSTR lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
LONG WINAPI RegSetValueExW(_In_ HKEY hKey, _In_ LPCWSTR lpValueName, _In_ DWORD Reserved, _In_ DWORD dwType, _In_ CONST BYTE *lpData, _In_ DWORD cbData)
LONG WINAPI RegQueryValueExW(_In_ HKEY hkeyorg, _In_ LPCWSTR name, _In_ LPDWORD reserved, _In_ LPDWORD type, _In_ LPBYTE data, _In_ LPDWORD count)
#define HeapFree(x, y, z)
int WINAPI lstrcmpiW(LPCWSTR str1, LPCWSTR str2)
HRESULT WINAPI SHGetFolderPathW(HWND hwndOwner, int nFolder, HANDLE hToken, DWORD dwFlags, LPWSTR pszPath)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
LPWSTR WINAPI lstrcatW(LPWSTR lpString1, LPCWSTR lpString2)
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
#define REG_OPTION_NON_VOLATILE
#define REG_OPENED_EXISTING_KEY
#define HKEY_CURRENT_USER
BOOL WINAPI GetWindowPlacement(_In_ HWND, _Inout_ WINDOWPLACEMENT *)
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)
BOOL WINAPI RemoveMenu(_In_ HMENU, _In_ UINT, _In_ UINT)
BOOL WINAPI GetMenuItemInfoW(_In_ HMENU, _In_ UINT, _In_ BOOL, _Inout_ LPMENUITEMINFOW)
struct _WINDOWPLACEMENT WINDOWPLACEMENT
HMENU WINAPI GetMenu(_In_ HWND)
BOOL WINAPI InsertMenuItemW(_In_ HMENU, _In_ UINT, _In_ BOOL, _In_ LPCMENUITEMINFOW)
struct tagMENUITEMINFOW MENUITEMINFOW
BOOL WINAPI SetRect(_Out_ LPRECT, _In_ int, _In_ int, _In_ int, _In_ int)
#define ID_FILE_RECENT_SEPARATOR
#define FILELIST_ENTRY_LENGTH
#define ID_WORDWRAP_WINDOW