lecui 1.0.0-alpha.20
lecui C++ user interface library
filesystem.h
1//
2// filesystem.h - filesystem interface
3//
4// lecui user interface library, part of the liblec library
5// Copyright (c) 2019 Alec Musasa (alecmus at live dot com)
6//
7// Released under the MIT license. For full details see the
8// file LICENSE.txt
9//
10
11#pragma once
12
13#if defined(LECUI_EXPORTS)
14#include "../form.h"
15#else
16#include <liblec/lecui/form.h>
17#endif
18
19namespace liblec {
20 namespace lecui {
22 class lecui_api filesystem {
23 public:
27
30
34 [[nodiscard]] std::string select_folder(const std::string& title);
35
39 [[nodiscard]] std::vector<std::string> open_file(const open_file_params& params);
40
47 [[nodiscard]] std::string save_file(const std::string& file,
48 const save_file_params& params);
49
50 private:
51 class impl;
52 impl& _d;
53
54 // Default constructor and copying an object of this class are not allowed
55 filesystem() = delete;
56 filesystem(const filesystem&) = delete;
57 filesystem& operator=(const filesystem&) = delete;
58 };
59 }
60}
Interact with the OS file system.
Definition: filesystem.h:22
std::string select_folder(const std::string &title)
Display a 'select folder' modal dialog.
std::vector< std::string > open_file(const open_file_params &params)
Display an 'open file' modal dialog.
std::string save_file(const std::string &file, const save_file_params &params)
Display a 'save file' modal dialog so the user can select its properties and location.
filesystem(form &fm)
Constructor.
Form base class. The user must inherit from this class and call one of the two constructors from its ...
Definition: form.h:122
Open file parameters.
Definition: lecui.h:702
Save file parameters.
Definition: lecui.h:783
Top level namespace for the liblec libraries.
Definition: appearance.h:19