cnjinhao / nana Goto Github PK
View Code? Open in Web Editor NEWa modern C++ GUI library
Home Page: https://nana.acemind.cn
License: Boost Software License 1.0
a modern C++ GUI library
Home Page: https://nana.acemind.cn
License: Boost Software License 1.0
I have tested multiple display monitor support feature (nana/gui/screen.hpp) in ver 1.0.1 .
And met the issue.
Currently, nana::screen implementation uses these Windows APIs.
In my testing environment, return value of screen::count method (which uses EnumDisplayDevices to check the number of monitors) is more than the number of attached monitors.
It seems like EnumDisplayDevices enumerate adapters instead of monitors.
and in nana::real_display constructor, EnumDisplaySettings API returned 0(failed).
I could get the number of phyisical moniors with another APIs.
Below are the sample code.
#include <nana/gui/screen.hpp>
#include <Windows.h>
using namespace nana;
BOOL __stdcall MyInfoEnumProc(HMONITOR hMon, HDC hDC, LPRECT rect, LPARAM lParam)
{
MONITORINFOEX mi;
mi.cbSize = sizeof(MONITORINFOEX);
if (GetMonitorInfo(hMon, &mi)) {
int hoge = 0;
}
return TRUE;
}
int main()
{
EnumDisplayMonitors(NULL, NULL, MyInfoEnumProc, 0);
int num = GetSystemMetrics(SM_CMONITORS);
#if 0
using namespace nana;
auto s = screen();
int count = s.count();
int test = 0;
s.for_each([&](display& d){
int hoge = 0;
});
#endif
}
Quote from http://stackoverflow.com/questions/18022612/enumerating-monitors-on-a-computer/18263412#18263412
Then, there is a difference between display adapters and monitors. EnumDisplayDevices shows you adapters and EnumDisplayMonitors shows you the monitors. The former is primarily to just enumerate the adapters but the latter allows you to provide a clipping rectangle and determine which monitors that clipping rectangle happens to land on. This becomes useful when you have multiple active monitors and someone decides to do something that causes a draw that will straddle multiple monitors. You get to specify a callback to EnumDisplayMonitors and that callback will be invoked with some parameters (if memory serves me correctly one of the parameters was a subset of the specified clipping rectangle that lands on the specified monitor).
Is include/nana/config.hpp
computer generated? If so it should be removed from git repo and added to the gitignore. My machine generates a different one after the build and shows up in git status
as modified.
On a related note, is there a reason why fixes are not merged into master right away? I understand new features may go into a development branch first but I don't understand why fixes for the master are not on the master right away. If a new user downloads the repo and tries to build he could run into the same problem again unless he knows to check out the hotfix branch instead, which is unlikely. If you want to have versioned releases I suppose you can always create named tags for the corresponding commits.
I want to use Nana as a git submodule for a project.
My project structure is as follows
source/ -> project source files
external/ -> git submodules, nana is located here
CMakeLists.txt
After attempting an out of source build with cmake, I get the following error
CMake Error at external/nana/CMakeLists.txt:146 (add_executable):
Cannot find source file:
test.cpp
which seems to be caused by the cmake line
add_subdirectory(external/nana)
OS: Ubuntu 14.04 LTS, 64 Bit
CMake: 3.2.2
Nana branch: Master
CMakeLists.txt
When compiling the development branch using the project in build\vc2015
and VS2015 Enterprise, the compiler gives the following error:
c:\users\waty\source\repos\nana\source\gui\element.cpp(267): error C2662: 'nana::rectangle &nana::rectangle::pare_off(int)': cannot convert 'this' pointer from 'const nana::rectangle' to 'nana::rectangle &'
The error disapears when you change
graph.rectangle(::nana::rectangle{ r }.pare_off(1), false, bgcolor);
to
graph.rectangle(::nana::rectangle(r).pare_off(1), false, bgcolor);
Hi,
could you tag the last commit with a new sub-sub-version number?
Hi,
I'm using the list model.
It was simple to set, and is working very fast (tested 50 000 items) but I have two problems: (sorry is long, but trivial)
item_data::to_string()
which have no idea of the model and have an empty cells
which throw out of index.targets_comp
object.So... it maybe crazy (we have to many different possibilities!) but maybe we can set four more members (std::funtions) on the header object : to_string()
, to_cell
, set_value()
and comp()
each taking a reference to the model object (CProgParam_SondeDesign::targets_comp&
- in my case)? It will be very easy to setup, more consistent ....
list.append_header( "T Pos", 60);
list.append_header( "T Cand", 60);
list.append_header( "N Pos", 60);
list.append_header( "N Cand", 60);
list.append_header( "Targ #", 50);
list.append_header( "Targ name", 100);
list.append_header( "N Cand", 60);
list.append_header( "N Pos", 60);
list.append_header( "Num T Hits", 80);
list.append_header( "Num Hits OK", 80);
list.append_header( "N Pos", 60);
list.append_header( "N Cand", 60);
list.append_header( "Iterat#", 80);
list.append_header( "Targ name", 100);
list.append_header( "N Cand", 60);
list.append_header( "N Pos", 60);
list.append_header( "T Pos", 60);
list.append_header( "T Cand", 60);
auto value_translator = [](const std::vector<nana::listbox::cell>& cells)
{
CProgParam_SondeDesign::targets_comp p;
int i = 0;
p.before.t_n_pos = std::stol(cells[i++].text); // "Num T Pos",
p.before.t_n_cand = std::stol(cells[i++].text); // "Num T Cand",
p.before.target_1_n_cand_pos = std::stol(cells[i++].text); // "Num Pos",
p.before.target_1_n_cand = std::stol(cells[i++].text); // "Num Cand",
p.target_num = std::stol(cells[i++].text); // "Targ Num",
p.target_1_name = cells[i++].text ; // "Targ name",
p.after.target_1_n_cand = std::stol(cells[i++].text); // "Num Cand",
p.after.target_1_n_cand_pos = std::stol(cells[i++].text); // "Num Pos",
p.iteration_num = std::stol(cells[i++].text); // "Num T Hits", ????????????????????
p.iteration_num = std::stol(cells[i++].text); // "Num Hits OK", ????????????????????
p.before.target_2_n_cand_pos = std::stol(cells[i++].text); // "Num Pos",
p.before.target_2_n_cand = std::stol(cells[i++].text); // "Num Cand",
p.iteration_num = std::stol(cells[i++].text); // "Iterat#",
p.target_2_name = cells[i++].text; // "Targ name",
p.after.target_2_n_cand = std::stol(cells[i++].text); // "Num Cand",
p.after.target_2_n_cand_pos = std::stol(cells[i++].text); // "Num Pos",
p.after.t_n_pos = std::stol(cells[i++].text); // "Num T Pos",
p.after.t_n_cand = std::stol(cells[i++].text); // "Num T Cand",
return p;
};
auto cell_translator = [](const CProgParam_SondeDesign::targets_comp& p)
{
std::vector<nana::listbox::cell> cells;
cells.emplace_back(std::to_string(p.before.t_n_pos ) );
cells.emplace_back(std::to_string(p.before.t_n_cand ) );
cells.emplace_back(std::to_string(p.before.target_1_n_cand_pos ) );
cells.emplace_back(std::to_string(p.before.target_1_n_cand ) );
cells.emplace_back(std::to_string(p.target_num ) );
cells.emplace_back( (p.target_1_name ) );
cells.emplace_back(std::to_string(p.after.target_1_n_cand ) );
cells.emplace_back(std::to_string(p.after.target_1_n_cand_pos ) );
cells.emplace_back(std::to_string(p.iteration_num ) );
cells.emplace_back(std::to_string(p.iteration_num ) );
cells.emplace_back(std::to_string(p.before.target_2_n_cand_pos ) );
cells.emplace_back(std::to_string(p.before.target_2_n_cand ) );
cells.emplace_back(std::to_string(p.iteration_num ) );
cells.emplace_back( (p.target_2_name ) );
cells.emplace_back(std::to_string(p.after.target_2_n_cand ) );
cells.emplace_back(std::to_string(p.after.target_2_n_cand_pos ) );
cells.emplace_back(std::to_string(p.after.t_n_pos ) );
cells.emplace_back(std::to_string(p.after.t_n_cand ) );
return cells;
};
list.at(0).model<std::recursive_mutex>(std::move(targets_comparitions), value_translator, cell_translator);
I think hidden widgets should not retain focus. If it has a focus, its focus should be lost.
Hi Jinhao,
i'm facing an error with Menus and opening a modal Dialog.
A stripped down sample as the following shows the error:
#include <nana/gui.hpp>
#include <nana/gui/place.hpp>
#include <nana/gui/widgets/menubar.hpp>
int main(int argc, char **argv)
{
nana::form fm;
nana::place pl(fm);
nana::menubar mn(fm);
pl.div("<vertical <menu weight=25>>");
pl.field("menu") << mn;
mn.push_back(L"test");
mn.at(0).append(L"open modal window", [&fm](nana::menu::item_proxy& ip)
{
nana::form fm2(fm);
fm2.show();
fm2.modality();
});
pl.collocate();
fm.show();
nana::exec();
return 0;
}
After opening fm2
via the Menu and closing the Form, the error occurs.
last callstack entry is:
0 0x00000000005781b6 std::unique_ptr<nana::basic_event<nana::arg_mouse>::docker, std::default_delete<nana::basic_event<nana::arg_mouse>::docker> >::~unique_ptr
if i understand correctly, the error occurs in the destructor of an unique_ptr
.
The system i'm using is nana with the latest master branch, windows 8.1 with mingw (gcc 4.9.2).
If you need further information please let me know.
best regards, jan
^
additional note:
if you open a window via a button or something else, no error occurs. this makes me guess the error is relating to menubars
Hi,
congratulation, I compiled all the 50 examples with VS2015 in Windows 7 Pro 64x using debug Win32 and static linked cpp run time:
(I returned some configuration to the project)
Commit: e46c5e4 [e46c5e4]
Parents: 09b314b
Author: Jinhao [email protected]
Date: Donnerstag, 22. Oktober 2015 18:56:10
Labels: HEAD, nana_jinhao/develop, cnjinhao/develop, develop
fix leak of memory for class animation
and with 0 errors and 0 warnings.
Now I will run each and test and will write here the results.
More info here. In short: std::wstring
sucks on Linux systems. Badly.
I thought slider's knob stays on the position when I clicked it. But it stopped on a different position (left side). After some testing, I noticed uninitialized slider doesn't behave as I thought. If I called vmax & value methods of slider widget, It behaves normally.
I still haven't looked up into the source code of the widget to figure out the cause. Probablly it would be of no harm to initialize some member variables in a constructor.
Additionally, this is a subtle thing but slider's knob moves one pixel left after I clicked a slider.
Please run below sample code and click various positions of sl3 slider and make sure if the problem reproduces at your side.
#include <nana/gui.hpp>
#include <nana/gui/widgets/slider.hpp>
int main()
{
using namespace nana;
form fm(API::make_center(500, 500));
slider sl1(fm, rectangle(10, 10, 300, 10));
slider sl2(fm, rectangle(10, 50, 300, 10));
slider sl3(fm, rectangle(10, 90, 300, 10));
sl1.vmax(1000);
sl1.value(100);
sl2.vmax(2000);
sl2.value(2000);
//drawing{ fm }.draw([](paint::graphics& graph){
// graph.string({ 10, 10 }, L"Hello, world!", colors::red);
//});
//fm.events().click(API::exit);
fm.show();
exec();
}
Compile error appears when I try to build a program that uses API::enum_widgets.
Usage is like this.
API::enum_widgets(fm, false, [&](::nana::widget& widget){
if (widget.handle() == mb.handle()) {
return;
}
if (bShowPreview) {
widget.hide();
}else {
widget.show();
}
});
It seems the cause is with this commit, Revision: 1b5aed2
File : include/nana/gui/programming_interface.hpp
In nana::detail::enum_widgets_function::_m_enum_fn(), new implementation supplies two argments to _m_enum_call method.
After removing 2nd argment nullptr, the compile error is no more.
Hi,
when i run this simple program:
#include <nana/gui.hpp>
int main()
{
nana::form f;
f.show();
nana::exec();
return 0;
}
it starts windowed and takes 2MB of ram, very much for a simple form.
When i maximize the form, it suddenly takes up to 18MB of ram.
If I add widgets, it suddenly uses even more than that, and i mean not just some more bytes, but again Megabytes more.
This happens in Debug and Release mode, and is independent from the used compiler (tried vc2015 and mingw 5.1) at least on Windows 10. I'm not able to test on other platforms currently.
in my opinion the ram usage is way to high.
is this known and accepted or is somebody working on it?
can we do something to get the ram usage lower?
best regards, jan
Hi, I'd like to use submenus in a menu bar but so far I can't make it work.
I use below code to check the issue. Could you please take a look at it?
#include <nana/gui.hpp>
#include <nana/gui/widgets/menubar.hpp>
int main()
{
using namespace nana;
form fm(API::make_center(500, 300));
fm.caption(L"submenu test");
menubar mb(fm);
mb.push_back(L"&File");
mb.push_back(L"&View");
auto& menu_view = mb.at(1);
menu_view.append(L"Test 0");
menu_view.append(L"Test 1");
menu_view.create_sub_menu(1)->append(L"aa");
// from http://nanapro.org/en-us/help/widgets/menu.htm
menu mobj;
mobj.append(STR("Item 0"));
mobj.append(STR("Item 1"));
mobj.create_sub_menu(1)->append(STR("A sub menu item"));
mobj.renderer(mobj.renderer());
mobj.item_pixels(30);
fm.events().click(menu_popuper(mobj));
fm.show();
exec();
}
Using CMake, gcc 5.3 and Fedora 23 64-bit:
After setting CMAKE_INSTALL_PREFIX to specify the installation directory, the build succeeds but the installation directory contains only libnana.a. The install directory should also contain the required include files.
Hi,
Editing in combox back key erase a char but del dont work
I am again trying to use Nana as a submodule for a project and encountered the following warning when generating the project with CMake.
I am using CMake 3.2.0 on Windows 7 and using the "develop" branch
CMake Warning (dev) at external/nana/CMakeLists.txt:8 (if):
Policy CMP0054 is not set: Only interpret if() arguments as variables or
keywords when unquoted. Run "cmake --help-policy CMP0054" for policy
details. Use the cmake_policy command to set the policy and suppress this
warning.Quoted variables like "MSVC" will no longer be dereferenced when the policy
is set to NEW. Since the policy is not set the OLD behavior will be used.
This warning is for project developers. Use -Wno-dev to suppress it.
Is it possible to set this policy as it adds to the overall noise of warnings which might actually break something someday
Inside the method:
void trigger::mouse_down(graph_reference, const arg_mouse& arg) { ... }
It is essential to check for the item pointer or the application will crash when selecting a category:
if (!lister.single_selection()){ ... } else { if (item_ptr) { sel = !item_proxy(essence_, index_pair(item_pos.cat, lister.absolute(item_pos))).selected(); } }
if the listbox was created with enable_single.
This is hard to explain. I open up the Notepad demo app. If I cycle between a
, s
, and d
, the text cursor will start jumping down and up and left and right and inserting newlines. Pressing the space tends to move up a line.
In the place_login demo app, doing the same thing looks fine. However:
a
, s
, and d
again, the text cursor will gradually move to the right.Also, API::exit
doesn't seem to exit anything. The window just stays there.
I love Nana, but this is just insane.
The CMakeLists.txt file uses the following lines to collect all relevant source files
set(NANA_SOURCE_DIR ${CMAKE_SOURCE_DIR}/source)
set(NANA_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/include)
Which causes major problems when using Nana as a sub project in cmake.
The lines should be changed to
set(NANA_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/source)
set(NANA_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include)
MINGW64 /c/libs/nana/build/bin/netbeans8 (origin/hotfix-1.3)
$ mingw32-make.exe
Scanning dependencies of target nana
[ 1%] Building CXX object CMakeFiles/nana.dir/source/any.cpp.obj
[ 2%] Building CXX object CMakeFiles/nana.dir/source/basic_types.cpp.obj
[ 3%] Building CXX object CMakeFiles/nana.dir/source/charset.cpp.obj
[ 5%] Building CXX object CMakeFiles/nana.dir/source/datetime.cpp.obj
[ 6%] Building CXX object CMakeFiles/nana.dir/source/deploy.cpp.obj
[ 7%] Building CXX object CMakeFiles/nana.dir/source/internationalization.cpp.obj
C:\libs\nana\source\internationalization.cpp:254:4: error: 'recursive_mutex' in namespace 'std' does not name a type
std::recursive_mutex mutex;
^
C:\libs\nana\source\internationalization.cpp: In function 'void nana::internationalization_parts::set_eval(nana::window, nana::i18n_eval&&)':
C:\libs\nana\source\internationalization.cpp:267:20: error: 'recursive_mutex' is not a member of 'std'
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:267:20: error: 'recursive_mutex' is not a member of 'std'
C:\libs\nana\source\internationalization.cpp:267:40: error: template argument 1 is invalid
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:267:46: error: invalid type in declaration before '(' token
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:267:51: error: 'struct nana::internationalization_parts::eval_manager' has no member named 'mutex'
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp: In lambda function:
C:\libs\nana\source\internationalization.cpp:274:22: error: 'recursive_mutex' is not a member of 'std'
std::lock_guardstd::recursive_mutex lockgd(eval_mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:274:22: error: 'recursive_mutex' is not a member of 'std'
C:\libs\nana\source\internationalization.cpp:274:42: error: template argument 1 is invalid
std::lock_guardstd::recursive_mutex lockgd(eval_mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:274:50: error: invalid type in declaration before '(' token
std::lock_guardstd::recursive_mutex lockgd(eval_mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:274:60: error: 'struct nana::internationalization_parts::eval_manager' has no member named 'mutex'
std::lock_guardstd::recursive_mutex lockgd(eval_mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp: In function 'void nana::internationalization_parts::use_eval()':
C:\libs\nana\source\internationalization.cpp:286:20: error: 'recursive_mutex' is not a member of 'std'
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:286:20: error: 'recursive_mutex' is not a member of 'std'
C:\libs\nana\source\internationalization.cpp:286:40: error: template argument 1 is invalid
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:286:46: error: invalid type in declaration before '(' token
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
C:\libs\nana\source\internationalization.cpp:286:51: error: 'struct nana::internationalization_parts::eval_manager' has no member named 'mutex'
std::lock_guardstd::recursive_mutex lock(mgr.mutex);
^
CMakeFiles\nana.dir\build.make:187: recipe for target 'CMakeFiles/nana.dir/source/internationalization.cpp.obj' failed
mingw32-make[2]: *** [CMakeFiles/nana.dir/source/internationalization.cpp.obj] Error 1
CMakeFiles\Makefile2:66: recipe for target 'CMakeFiles/nana.dir/all' failed
mingw32-make[1]: *** [CMakeFiles/nana.dir/all] Error 2
Makefile:126: recipe for target 'all' failed
mingw32-make: *** [all] Error 2
Hi !
I'm adapting my app from v1.1 to v1.3
I know I have problems with non ASCII characters that I need to make utf8 now.
But anyway, I'm using the "opportunity" to improve the error handling of my app.
I'm catching exceptions and adding nice messages.
It is more difficult that I wanted.
Here are some of my problems:
throw_not_utf8
, but print a cerr error and continue with the crappy text. (it will change only the code of throw_not_utf8
)msgbox
will refuse and will throw! if you try to report that text. msgbox
is therefore a good candidate to force (using some explicit arg ) non utf8, crappy print.msgbox
in the catch
of an exception - which is very natural - and it terminate the program and you don't have any idea why.throw_not_utf8
.is_destroying
is not always working, and it is difficult to debug why. When it throw here the program is killed. //Listen to destroy of a window
//It will delete the element and recollocate when the window destroyed.
event_handle _m_make_destroy(window wd)
{
return API::events(wd).destroy.connect([this, wd](const arg_destroy&)
{
for (auto i = elements.begin(), end = elements.end(); i != end; ++i)
{
if (!API::is_destroying(API::get_parent_window(wd)))
place_ptr_->collocate();
}
});
}
BDW - I don't understand what is with the iteratori
that is not used, maybe you wanted i->collocate();
? ...
Hi, guys
@ierofant , @roberthauck , @qPCR4vir please update the cmake file for config.hpp if you have spare time. Thank you.
The config.hpp has been separated into two parts. (develop branch)
Some symbols, such as adaption of target OS, workarounds compiler errors and lack of std C++ supports, are defined in c++defines.hpp. This part should not be modified by developer, these symbols is detected automatically.
Some symbols for external libraries are defined in config.hpp. Developers can modify the symbols defined in config.hpp to enable/disable features.
BTW, another question. What versions of libstdc++ and libc++ support std::make_unique? I only know GCC 4.9 supports std::make_unique, but I have now idea what version of libstdc++ is.
Hi,
When I attach a second display to my laptop and make it the principal display all work OK.
But if the attached display is secondary when my nana program is there, the tooltip and menus open in different wrong place.
Other programs run OK.
I was thinking this is a new problem, but not. All my old executable have the same problems, just that I always used the attached display as principal.
I use Windows 7 pro x64
Hi,
When I built nana on Linux, there was an error on source/detail/linux_X11/platform_spec.cpp
.
[ 12%] Building CXX object CMakeFiles/nana.dir/source/detail/platform_spec_selector.cpp.o
/usr/bin/clang++ -DNANA_ENABLE_PNG -DNANA_LIBPNG -DNANA_LINUX -DNANA_UNICODE -DNANA_X11 -DPLATFORM_SPEC_HPP="<nana/detail/linux_X11/platform_spec.hpp>" -DSTD_CODECVT_NOT_SUPPORTED -std=c++11 -Wall -I/usr/include/freetype2 -I/home/cocoa/.ghq/github.com/cnjinhao/nana/include -o CMakeFiles/nana.dir/source/detail/platform_spec_selector.cpp.o -c /home/cocoa/.ghq/github.com/cnjinhao/nana/source/detail/platform_spec_selector.cpp
In file included from /home/cocoa/.ghq/github.com/cnjinhao/nana/source/detail/platform_spec_selector.cpp:21:
/home/cocoa/.ghq/github.com/cnjinhao/nana/source/detail/linux_X11/platform_spec.cpp:47:34: error: invalid operands to binary expression ('std::ifstream' (aka 'basic_ifstream<char>') and 'int')
return static_cast<bool>(ifs_ != 0);
~~~~ ^ ~
1 error generated.
[ 12%] Building CXX object CMakeFiles/nana.dir/source/detail/platform_spec_selector.cpp.o
/usr/bin/c++ -DNANA_ENABLE_PNG -DNANA_LIBPNG -DNANA_LINUX -DNANA_UNICODE -DNANA_X11 -DPLATFORM_SPEC_HPP="<nana/detail/linux_X11/platform_spec.hpp>" -DSTD_CODECVT_NOT_SUPPORTED -std=c++11 -Wall -I/usr/include/freetype2 -I/home/cocoa/.ghq/github.com/cnjinhao/nana/include -o CMakeFiles/nana.dir/source/detail/platform_spec_selector.cpp.o -c /home/cocoa/.ghq/github.com/cnjinhao/nana/source/detail/platform_spec_selector.cpp
In file included from /home/cocoa/.ghq/github.com/cnjinhao/nana/source/detail/platform_spec_selector.cpp:21:0:
/home/cocoa/.ghq/github.com/cnjinhao/nana/source/detail/linux_X11/platform_spec.cpp: In member function โbool nana::detail::conf::open(const char*)โ:
/home/cocoa/.ghq/github.com/cnjinhao/nana/source/detail/linux_X11/platform_spec.cpp:47:34: error: no match for โoperator!=โ (operand types are โstd::ifstream {aka std::basic_ifstream<char>}โ and โintโ)
return static_cast<bool>(ifs_ != 0);
^
Could you check this, please?
why i can not find ft2builder but libfreetype2 and libfreetype2-dev are installed and their links are exists in /usr/include/freetype2/ft2build.h
When I press Alt + Space key with typical Windows application,
it displays active window's system menu.
Please search "ALT+SPACE" in below page.
https://msdn.microsoft.com/en-us/library/ms971323.aspx
I confirmed that putting another
def_window_proc = true;
before the break of case WM_SYSCHAR: in nana::detail::Bedrock_WIN32_WindowProc function can solve the issue.
I don't think changing the click
event from basic_event<arg_mouse>
to basic_event<arg_click>
is a good idea. It causes losing many useful infomations and making the click
and dbl_click
acting quite differently.
Perhap inheriting arg_click
from arg_mouse
is more suitable.
ps:why the Alt key disappeared from
nana
?
struct arg_mouse
: public event_arg
{
event_code evt_code; ///<
::nana::window window_handle; ///< A handle to the event window
::nana::point pos; ///< cursor position in the event window
::nana::mouse button; ///< indicates a button which triggers the event
bool left_button; ///< mouse left button is pressed?
bool mid_button; ///< mouse middle button is pressed?
bool right_button; ///< mouse right button is pressed?
bool shift; ///< keyboard Shift is pressed?
bool ctrl; ///< keyboard Ctrl is pressed?
};
struct arg_click : public event_arg
{
::nana::window window_handle; ///< A handle to the event window
bool by_mouse; ///< Determines whether the event is emitted by clicking mouse button
};
basic_event<arg_click> click; ///< the window is clicked, but occurs after mouse_down and before mouse_up
basic_event<arg_mouse> dbl_click; ///< the window is double clicked
Line size of RGB bitmap must be 4 byte aligned and internally it is so.
The problem appears when graphics width is not multiple of 4.
I modified the code to resolve the problem.
void graphics::save_as_file(const char* file) const
{
if(handle_)
{
#if defined(NANA_WINDOWS)
int iWidth = static_cast<int>(size_.width);
int iHeight = static_cast<int>(size_.height);
BITMAPINFO bmpInfo = {};
bmpInfo.bmiHeader.biSize = sizeof(bmpInfo.bmiHeader);
bmpInfo.bmiHeader.biWidth = static_cast<int>(size_.width);
bmpInfo.bmiHeader.biHeight = static_cast<int>(size_.height);
bmpInfo.bmiHeader.biPlanes = 1;
bmpInfo.bmiHeader.biBitCount = 24;
const size_t lineBytes = ((bmpInfo.bmiHeader.biWidth * 3) + 3) & (~3);
const size_t imageBytes = iHeight * lineBytes;
HDC hdcMem = ::CreateCompatibleDC(handle_->context);
BYTE *pData = nullptr;
HBITMAP hBmp = CreateDIBSection(hdcMem, &bmpInfo, DIB_RGB_COLORS, reinterpret_cast<void**>(&pData), 0, 0);
::SelectObject(hdcMem, hBmp);
BitBlt(hdcMem, 0, 0, iWidth, iHeight, handle_->context, 0, 0, SRCCOPY);
BITMAPFILEHEADER bmFileHeader = {0};
bmFileHeader.bfType = 0x4d42; //bmp
bmFileHeader.bfOffBits = sizeof(BITMAPFILEHEADER) + sizeof(BITMAPINFOHEADER);
bmFileHeader.bfSize = bmFileHeader.bfOffBits + imageBytes;
HANDLE hFile = CreateFileA(file, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
DWORD dwWrite = 0;
WriteFile(hFile, &bmFileHeader, sizeof(BITMAPFILEHEADER), &dwWrite, NULL);
WriteFile(hFile, &bmpInfo.bmiHeader, sizeof(BITMAPINFOHEADER), &dwWrite, NULL);
WriteFile(hFile, pData, imageBytes, &dwWrite, NULL);
CloseHandle(hFile);
::DeleteObject(hBmp);
::DeleteDC(hdcMem);
#elif defined(NANA_X11)
#endif
}
}
nana displays below message with MessageBoxA
.
---------------------------
Nana C++ Library
---------------------------
Nana.GUI detects a memory leaks in events operation, 1 event(s) are not uninstalled.
---------------------------
OK
---------------------------
Below are the code to reproduce.
#include <nana/gui.hpp>
int main()
{
using namespace nana;
form fm(API::make_center(300, 300));
fm.events().click([&](const arg_mouse& arg){
msgbox mb(fm, L"test", msgbox::ok);
mb.icon(mb.icon_question);
mb << L"Test";
mb.show();
});
#if 0
fm.show();
exec();
#else
fm.modality();
#endif
}
Typically top level root window doesn't need to be shown with modality
method, but I switched non-top-level window to be top-level-window for testing purpose (I wanted to skip tedious operations to open child form during testing).
And I wish the messages will be displayed in output window. The error message is displayed on MessageBox in debug & release build but that makes end-user be causcious of the inner problem.
Other Windows applications as I know of so far handle Alt + F4 key.
So I thought It would be fine if nana library could handle the key down as a user's operation to close the form. And... sorry, I don't remeber if applications on X Window behaves the same.
Here's what I get (I filtered out lines that show commands that succeeded):
clang++ -g -c ../../source/internationalization.cpp -o ../../source/internationalization.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/internationalization.cpp:13:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/internationalization.o] Error 1
clang++ -g -c ../../source/unicode_bidi.cpp -o ../../source/unicode_bidi.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/unicode_bidi.cpp:961:34: warning: unused variable 'last' [-Wunused-variable]
std::vector<entity>::iterator last = end - 1;
^
1 warning generated.
clang++ -g -c ../../source/gui/animation.cpp -o ../../source/gui/animation.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/animation.cpp:14:
In file included from ../../include/nana/gui/drawing.hpp:14:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/animation.o] Error 1
clang++ -g -c ../../source/gui/drawing.cpp -o ../../source/gui/drawing.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/drawing.cpp:13:
In file included from ../../include/nana/gui/drawing.hpp:14:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/drawing.o] Error 1
clang++ -g -c ../../source/gui/filebox.cpp -o ../../source/gui/filebox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/filebox.cpp:1:
In file included from ../../include/nana/gui/filebox.hpp:3:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/filebox.cpp:1:
In file included from ../../include/nana/gui/filebox.hpp:3:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/label.hpp:52:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::label::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::label::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/button.hpp:80:13: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::button::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::button::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/listbox.hpp:444:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::listbox::trigger, nana::drawerbase::listbox::listbox_events>' requested here
: public widget_object<category::widget_tag, drawerbase::listbox::trigger, drawerbase::listbox::listbox_events>,
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/textbox.hpp:99:11: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::textbox::drawer, nana::drawerbase::textbox::textbox_events>' requested here
:public widget_object<category::widget_tag, drawerbase::textbox::drawer, drawerbase::textbox::textbox_events>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/treebox.hpp:357:11: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::treebox::trigger, nana::drawerbase::treebox::treebox_events>' requested here
:public widget_object < category::widget_tag, drawerbase::treebox::trigger, drawerbase::treebox::treebox_events>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/combox.hpp:163:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::combox::trigger, nana::drawerbase::combox::combox_events>' requested here
: public widget_object<category::widget_tag, drawerbase::combox::trigger, drawerbase::combox::combox_events>,
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/categorize.hpp:154:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::categorize::trigger, nana::drawerbase::categorize::categorize_events<int> >' requested here
: public widget_object<category::widget_tag, drawerbase::categorize::trigger, drawerbase::categorize::categorize_events<T>>
^
../../source/gui/filebox.cpp:807:19: note: in instantiation of template class 'nana::categorize<int>' requested here
categorize<int> path_;
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
7 warnings and 2 errors generated.
make: *** [../../source/gui/filebox.o] Error 1
clang++ -g -c ../../source/gui/layout_utility.cpp -o ../../source/gui/layout_utility.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
clang++ -g -c ../../source/gui/msgbox.cpp -o ../../source/gui/msgbox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/msgbox.cpp:17:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/msgbox.cpp:17:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/label.hpp:52:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::label::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::label::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/button.hpp:80:13: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::button::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::button::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/picture.hpp:59:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::xpicture::picture_drawer, nana::general_events>' requested here
: public widget_object<category::widget_tag, xpicture::picture_drawer>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
3 warnings and 2 errors generated.
make: *** [../../source/gui/msgbox.o] Error 1
clang++ -g -c ../../source/gui/place.cpp -o ../../source/gui/place.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/place.cpp:19:
In file included from ../../include/nana/gui/widgets/label.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/place.cpp:19:
In file included from ../../include/nana/gui/widgets/label.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/label.hpp:52:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::label::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::label::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/place.o] Error 1
clang++ -g -c ../../source/gui/programming_interface.cpp -o ../../source/gui/programming_interface.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/programming_interface.cpp:17:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/programming_interface.o] Error 1
clang++ -g -c ../../source/gui/tooltip.cpp -o ../../source/gui/tooltip.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/tooltip.cpp:12:
In file included from ../../include/nana/gui/tooltip.hpp:14:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/tooltip.cpp:12:
In file included from ../../include/nana/gui/tooltip.hpp:14:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/label.hpp:52:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::label::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::label::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/tooltip.o] Error 1
clang++ -g -c ../../source/gui/wvl.cpp -o ../../source/gui/wvl.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/wvl.cpp:14:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/wvl.o] Error 1
clang++ -g -c ../../source/gui/detail/basic_window.cpp -o ../../source/gui/detail/basic_window.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
clang++ -g -c ../../source/gui/detail/bedrock_pi.cpp -o ../../source/gui/detail/bedrock_pi.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/detail/bedrock_pi.cpp:20:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/detail/bedrock_pi.o] Error 1
clang++ -g -c ../../source/gui/widgets/button.cpp -o ../../source/gui/widgets/button.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/button.cpp:13:
In file included from ../../include/nana/gui/widgets/button.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/button.cpp:13:
In file included from ../../include/nana/gui/widgets/button.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/button.hpp:80:13: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::button::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::button::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/widgets/button.o] Error 1
clang++ -g -c ../../source/gui/widgets/categorize.cpp -o ../../source/gui/widgets/categorize.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/categorize.cpp:13:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/categorize.o] Error 1
clang++ -g -c ../../source/gui/widgets/checkbox.cpp -o ../../source/gui/widgets/checkbox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/checkbox.cpp:12:
In file included from ../../include/nana/gui/widgets/checkbox.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/checkbox.cpp:12:
In file included from ../../include/nana/gui/widgets/checkbox.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/checkbox.hpp:56:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::checkbox::drawer, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::checkbox::drawer>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
In file included from ../../source/gui/widgets/checkbox.cpp:12:
../../include/nana/gui/widgets/checkbox.hpp:47:13: warning: private field 'state_' is not used [-Wunused-private-field]
unsigned state_;
^
2 warnings and 2 errors generated.
make: *** [../../source/gui/widgets/checkbox.o] Error 1
clang++ -g -c ../../source/gui/widgets/combox.cpp -o ../../source/gui/widgets/combox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/combox.cpp:13:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/combox.cpp:13:
In file included from ../../include/nana/gui/wvl.hpp:18:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/combox.hpp:163:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::combox::trigger, nana::drawerbase::combox::combox_events>' requested here
: public widget_object<category::widget_tag, drawerbase::combox::trigger, drawerbase::combox::combox_events>,
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/widgets/combox.o] Error 1
clang++ -g -c ../../source/gui/widgets/date_chooser.cpp -o ../../source/gui/widgets/date_chooser.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/date_chooser.cpp:12:
In file included from ../../include/nana/gui/widgets/date_chooser.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/date_chooser.cpp:12:
../../include/nana/gui/widgets/date_chooser.hpp:61:10: warning: 'refresh' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void refresh(graph_reference);
^
../../include/nana/gui/detail/drawer.hpp:38:16: note: overridden virtual function is here
virtual void refresh(graph_reference);
^
In file included from ../../source/gui/widgets/date_chooser.cpp:12:
In file included from ../../include/nana/gui/widgets/date_chooser.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/date_chooser.hpp:107:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::date_chooser::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::date_chooser::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../source/gui/widgets/date_chooser.cpp:52:11: warning: comparison of 0 <= unsigned expression is always true [-Wtautological-compare]
if(0 <= index && index < 7)
~ ^ ~~~~~
../../source/gui/widgets/date_chooser.cpp:58:11: warning: comparison of 0 <= unsigned expression is always true [-Wtautological-compare]
if(0 <= index && index < 12)
~ ^ ~~~~~
4 warnings and 2 errors generated.
make: *** [../../source/gui/widgets/date_chooser.o] Error 1
clang++ -g -c ../../source/gui/widgets/float_listbox.cpp -o ../../source/gui/widgets/float_listbox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/float_listbox.cpp:13:
In file included from ../../include/nana/gui/widgets/float_listbox.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:183:10: warning: 'attached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void attached(widget_reference widget, graph_reference graph)
^
../../include/nana/gui/widgets/widget.hpp:209:17: note: in instantiation of template class 'nana::drawerbase::scroll::trigger<true>' requested here
DrawerTrigger trigger_;
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/float_listbox.cpp:412:24: note: in instantiation of template class 'nana::scroll<true>' requested here
nana::scroll<true> scrollbar_;
^
../../include/nana/gui/detail/drawer.hpp:34:16: note: overridden virtual function is here
virtual void attached(widget_reference, graph_reference); //none-const
^
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:193:10: warning: 'detached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void detached()
^
../../include/nana/gui/detail/drawer.hpp:35:16: note: overridden virtual function is here
virtual void detached(); //none-const
^
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:198:10: warning: 'refresh' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void refresh(graph_reference graph)
^
../../include/nana/gui/detail/drawer.hpp:38:16: note: overridden virtual function is here
virtual void refresh(graph_reference);
^
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:216:10: warning: 'mouse_move' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:46:16: note: overridden virtual function is here
virtual void mouse_move(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:243:10: warning: 'mouse_down' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_down(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:48:16: note: overridden virtual function is here
virtual void mouse_down(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:278:10: warning: 'mouse_up' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_up(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:49:16: note: overridden virtual function is here
virtual void mouse_up(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:290:10: warning: 'mouse_leave' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_leave(graph_reference graph, const arg_mouse&)
^
../../include/nana/gui/detail/drawer.hpp:47:16: note: overridden virtual function is here
virtual void mouse_leave(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/float_listbox.cpp:14:
../../include/nana/gui/widgets/scroll.hpp:299:10: warning: 'mouse_wheel' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_wheel(graph_reference graph, const arg_wheel& arg)
^
../../include/nana/gui/detail/drawer.hpp:50:16: note: overridden virtual function is here
virtual void mouse_wheel(graph_reference, const arg_wheel&);
^
In file included from ../../source/gui/widgets/float_listbox.cpp:13:
In file included from ../../include/nana/gui/widgets/float_listbox.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/float_listbox.cpp:412:24: note: in instantiation of template class 'nana::scroll<true>' requested here
nana::scroll<true> scrollbar_;
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
9 warnings and 2 errors generated.
make: *** [../../source/gui/widgets/float_listbox.o] Error 1
clang++ -g -c ../../source/gui/widgets/form.cpp -o ../../source/gui/widgets/form.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/form.cpp:12:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/form.o] Error 1
clang++ -g -c ../../source/gui/widgets/frame.cpp -o ../../source/gui/widgets/frame.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/frame.cpp:14:
In file included from ../../include/nana/gui/widgets/frame.hpp:18:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/frame.o] Error 1
clang++ -g -c ../../source/gui/widgets/label.cpp -o ../../source/gui/widgets/label.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/label.cpp:13:
In file included from ../../include/nana/gui/widgets/label.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/label.cpp:13:
In file included from ../../include/nana/gui/widgets/label.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/label.hpp:52:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::label::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::label::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
In file included from ../../source/gui/widgets/label.cpp:15:
../../include/nana/gui/widgets/skeletons/text_token_stream.hpp:425:15: warning: private field 'whspace_size_' is not used [-Wunused-private-field]
std::size_t whspace_size_;
^
../../include/nana/gui/widgets/skeletons/text_token_stream.hpp:600:15: warning: private field 'limited_' is not used [-Wunused-private-field]
std::size_t limited_;
^
../../include/nana/gui/widgets/skeletons/text_token_stream.hpp:931:8: warning: private field 'format_enabled_' is not used [-Wunused-private-field]
bool format_enabled_;
^
4 warnings and 2 errors generated.
make: *** [../../source/gui/widgets/label.o] Error 1
clang++ -g -c ../../source/gui/widgets/listbox.cpp -o ../../source/gui/widgets/listbox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/listbox.cpp:15:
In file included from ../../include/nana/gui/widgets/listbox.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/listbox.cpp:15:
In file included from ../../include/nana/gui/widgets/listbox.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/listbox.hpp:444:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::listbox::trigger, nana::drawerbase::listbox::listbox_events>' requested here
: public widget_object<category::widget_tag, drawerbase::listbox::trigger, drawerbase::listbox::listbox_events>,
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:183:10: warning: 'attached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void attached(widget_reference widget, graph_reference graph)
^
../../include/nana/gui/widgets/widget.hpp:209:17: note: in instantiation of template class 'nana::drawerbase::scroll::trigger<true>' requested here
DrawerTrigger trigger_;
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/listbox.cpp:1723:25: note: in instantiation of template class 'nana::scroll<true>' requested here
nana::scroll<true> v;
^
../../include/nana/gui/detail/drawer.hpp:34:16: note: overridden virtual function is here
virtual void attached(widget_reference, graph_reference); //none-const
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:193:10: warning: 'detached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void detached()
^
../../include/nana/gui/detail/drawer.hpp:35:16: note: overridden virtual function is here
virtual void detached(); //none-const
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:198:10: warning: 'refresh' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void refresh(graph_reference graph)
^
../../include/nana/gui/detail/drawer.hpp:38:16: note: overridden virtual function is here
virtual void refresh(graph_reference);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:216:10: warning: 'mouse_move' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:46:16: note: overridden virtual function is here
virtual void mouse_move(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:243:10: warning: 'mouse_down' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_down(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:48:16: note: overridden virtual function is here
virtual void mouse_down(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:278:10: warning: 'mouse_up' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_up(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:49:16: note: overridden virtual function is here
virtual void mouse_up(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:290:10: warning: 'mouse_leave' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_leave(graph_reference graph, const arg_mouse&)
^
../../include/nana/gui/detail/drawer.hpp:47:16: note: overridden virtual function is here
virtual void mouse_leave(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:299:10: warning: 'mouse_wheel' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_wheel(graph_reference graph, const arg_wheel& arg)
^
../../include/nana/gui/detail/drawer.hpp:50:16: note: overridden virtual function is here
virtual void mouse_wheel(graph_reference, const arg_wheel&);
^
In file included from ../../source/gui/widgets/listbox.cpp:15:
In file included from ../../include/nana/gui/widgets/listbox.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/listbox.cpp:1723:25: note: in instantiation of template class 'nana::scroll<true>' requested here
nana::scroll<true> v;
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:183:10: warning: 'attached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void attached(widget_reference widget, graph_reference graph)
^
../../include/nana/gui/widgets/widget.hpp:209:17: note: in instantiation of template class 'nana::drawerbase::scroll::trigger<false>' requested here
DrawerTrigger trigger_;
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<false>, nana::drawerbase::scroll::scroll_events<false> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/listbox.cpp:1724:26: note: in instantiation of template class 'nana::scroll<false>' requested here
nana::scroll<false> h;
^
../../include/nana/gui/detail/drawer.hpp:34:16: note: overridden virtual function is here
virtual void attached(widget_reference, graph_reference); //none-const
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:193:10: warning: 'detached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void detached()
^
../../include/nana/gui/detail/drawer.hpp:35:16: note: overridden virtual function is here
virtual void detached(); //none-const
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:198:10: warning: 'refresh' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void refresh(graph_reference graph)
^
../../include/nana/gui/detail/drawer.hpp:38:16: note: overridden virtual function is here
virtual void refresh(graph_reference);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:216:10: warning: 'mouse_move' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:46:16: note: overridden virtual function is here
virtual void mouse_move(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:243:10: warning: 'mouse_down' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_down(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:48:16: note: overridden virtual function is here
virtual void mouse_down(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:278:10: warning: 'mouse_up' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_up(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:49:16: note: overridden virtual function is here
virtual void mouse_up(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:290:10: warning: 'mouse_leave' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_leave(graph_reference graph, const arg_mouse&)
^
../../include/nana/gui/detail/drawer.hpp:47:16: note: overridden virtual function is here
virtual void mouse_leave(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/listbox.cpp:16:
../../include/nana/gui/widgets/scroll.hpp:299:10: warning: 'mouse_wheel' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_wheel(graph_reference graph, const arg_wheel& arg)
^
../../include/nana/gui/detail/drawer.hpp:50:16: note: overridden virtual function is here
virtual void mouse_wheel(graph_reference, const arg_wheel&);
^
In file included from ../../source/gui/widgets/listbox.cpp:15:
In file included from ../../include/nana/gui/widgets/listbox.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<false>, nana::drawerbase::scroll::scroll_events<false> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/listbox.cpp:1724:26: note: in instantiation of template class 'nana::scroll<false>' requested here
nana::scroll<false> h;
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../source/gui/widgets/listbox.cpp:3026:38: warning: expression result unused [-Wunused-value]
cat_->items.at(pos_.item).flags.selected;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~
20 warnings and 2 errors generated.
make: *** [../../source/gui/widgets/listbox.o] Error 1
clang++ -g -c ../../source/gui/widgets/menubar.cpp -o ../../source/gui/widgets/menubar.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/menubar.cpp:13:
In file included from ../../include/nana/gui/widgets/menubar.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/menubar.cpp:13:
In file included from ../../include/nana/gui/widgets/menubar.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/menubar.hpp:102:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::menubar::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::menubar::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/widgets/menubar.o] Error 1
clang++ -g -c ../../source/gui/widgets/menu.cpp -o ../../source/gui/widgets/menu.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/menu.cpp:13:
In file included from ../../include/nana/gui/widgets/menu.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/menu.o] Error 1
clang++ -g -c ../../source/gui/widgets/panel.cpp -o ../../source/gui/widgets/panel.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/panel.cpp:14:
In file included from ../../include/nana/gui/widgets/panel.hpp:17:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/panel.o] Error 1
clang++ -g -c ../../source/gui/widgets/picture.cpp -o ../../source/gui/widgets/picture.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/picture.cpp:14:
In file included from ../../include/nana/gui/widgets/picture.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/picture.cpp:14:
In file included from ../../include/nana/gui/widgets/picture.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/picture.hpp:59:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::xpicture::picture_drawer, nana::general_events>' requested here
: public widget_object<category::widget_tag, xpicture::picture_drawer>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/widgets/picture.o] Error 1
clang++ -g -c ../../source/gui/widgets/progress.cpp -o ../../source/gui/widgets/progress.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/progress.cpp:12:
In file included from ../../include/nana/gui/widgets/progress.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/progress.cpp:12:
In file included from ../../include/nana/gui/widgets/progress.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/progress.hpp:57:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::progress::trigger, nana::general_events>' requested here
: public widget_object<category::widget_tag, drawerbase::progress::trigger>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
In file included from ../../source/gui/widgets/progress.cpp:12:
../../include/nana/gui/widgets/progress.hpp:47:10: warning: private field 'has_value_' is not used [-Wunused-private-field]
bool has_value_;
^
2 warnings and 2 errors generated.
make: *** [../../source/gui/widgets/progress.o] Error 1
clang++ -g -c ../../source/gui/widgets/scroll.cpp -o ../../source/gui/widgets/scroll.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/scroll.cpp:12:
In file included from ../../include/nana/gui/widgets/scroll.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/scroll.o] Error 1
clang++ -g -c ../../source/gui/widgets/slider.cpp -o ../../source/gui/widgets/slider.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/slider.cpp:2:
In file included from ../../include/nana/gui/widgets/slider.hpp:14:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/slider.cpp:2:
In file included from ../../include/nana/gui/widgets/slider.hpp:14:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/slider.hpp:113:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::slider::trigger, nana::drawerbase::slider::slider_events>' requested here
: public widget_object<category::widget_tag, drawerbase::slider::trigger, drawerbase::slider::slider_events>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/widgets/slider.o] Error 1
clang++ -g -c ../../source/gui/widgets/tabbar.cpp -o ../../source/gui/widgets/tabbar.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/tabbar.cpp:11:
In file included from ../../include/nana/gui/widgets/tabbar.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/tabbar.o] Error 1
clang++ -g -c ../../source/gui/widgets/textbox.cpp -o ../../source/gui/widgets/textbox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/textbox.cpp:13:
In file included from ../../include/nana/gui/widgets/textbox.hpp:14:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/textbox.cpp:13:
In file included from ../../include/nana/gui/widgets/textbox.hpp:14:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/textbox.hpp:99:11: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::textbox::drawer, nana::drawerbase::textbox::textbox_events>' requested here
:public widget_object<category::widget_tag, drawerbase::textbox::drawer, drawerbase::textbox::textbox_events>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/widgets/textbox.o] Error 1
clang++ -g -c ../../source/gui/widgets/toolbar.cpp -o ../../source/gui/widgets/toolbar.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/toolbar.cpp:12:
In file included from ../../include/nana/gui/widgets/toolbar.hpp:16:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/toolbar.cpp:12:
In file included from ../../include/nana/gui/widgets/toolbar.hpp:16:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/toolbar.hpp:85:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::toolbar::drawer, nana::drawerbase::toolbar::toolbar_events>' requested here
: public widget_object<category::widget_tag, drawerbase::toolbar::drawer, drawerbase::toolbar::toolbar_events>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
1 warning and 2 errors generated.
make: *** [../../source/gui/widgets/toolbar.o] Error 1
clang++ -g -c ../../source/gui/widgets/treebox.cpp -o ../../source/gui/widgets/treebox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/treebox.cpp:12:
In file included from ../../include/nana/gui/widgets/treebox.hpp:20:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
In file included from ../../source/gui/widgets/treebox.cpp:12:
In file included from ../../include/nana/gui/widgets/treebox.hpp:20:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/treebox.hpp:357:11: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::treebox::trigger, nana::drawerbase::treebox::treebox_events>' requested here
:public widget_object < category::widget_tag, drawerbase::treebox::trigger, drawerbase::treebox::treebox_events>
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:183:10: warning: 'attached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void attached(widget_reference widget, graph_reference graph)
^
../../include/nana/gui/widgets/widget.hpp:209:17: note: in instantiation of template class 'nana::drawerbase::scroll::trigger<true>' requested here
DrawerTrigger trigger_;
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/treebox.cpp:129:25: note: in instantiation of template class 'nana::scroll<true>' requested here
nana::scroll<true> scroll;
^
../../include/nana/gui/detail/drawer.hpp:34:16: note: overridden virtual function is here
virtual void attached(widget_reference, graph_reference); //none-const
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:193:10: warning: 'detached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void detached()
^
../../include/nana/gui/detail/drawer.hpp:35:16: note: overridden virtual function is here
virtual void detached(); //none-const
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:198:10: warning: 'refresh' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void refresh(graph_reference graph)
^
../../include/nana/gui/detail/drawer.hpp:38:16: note: overridden virtual function is here
virtual void refresh(graph_reference);
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:216:10: warning: 'mouse_move' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:46:16: note: overridden virtual function is here
virtual void mouse_move(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:243:10: warning: 'mouse_down' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_down(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:48:16: note: overridden virtual function is here
virtual void mouse_down(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:278:10: warning: 'mouse_up' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_up(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:49:16: note: overridden virtual function is here
virtual void mouse_up(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:290:10: warning: 'mouse_leave' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_leave(graph_reference graph, const arg_mouse&)
^
../../include/nana/gui/detail/drawer.hpp:47:16: note: overridden virtual function is here
virtual void mouse_leave(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/treebox.cpp:13:
../../include/nana/gui/widgets/scroll.hpp:299:10: warning: 'mouse_wheel' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_wheel(graph_reference graph, const arg_wheel& arg)
^
../../include/nana/gui/detail/drawer.hpp:50:16: note: overridden virtual function is here
virtual void mouse_wheel(graph_reference, const arg_wheel&);
^
In file included from ../../source/gui/widgets/treebox.cpp:12:
In file included from ../../include/nana/gui/widgets/treebox.hpp:20:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/treebox.cpp:129:25: note: in instantiation of template class 'nana::scroll<true>' requested here
nana::scroll<true> scroll;
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
../../source/gui/widgets/treebox.cpp:627:32: error: allocation of incomplete type 'nana::drawerbase::treebox::tooltip_window'
node_state.tooltip = new tooltip_window(data.widget_ptr->handle(), text_r);
^~~~~~~~~~~~~~
../../source/gui/widgets/treebox.cpp:74:10: note: forward declaration of 'nana::drawerbase::treebox::tooltip_window'
class tooltip_window;
^
../../source/gui/widgets/treebox.cpp:657:7: warning: deleting pointer to incomplete type 'nana::drawerbase::treebox::tooltip_window' may cause undefined behavior [-Wdelete-incomplete]
delete x;
^ ~
../../source/gui/widgets/treebox.cpp:74:10: note: forward declaration of 'nana::drawerbase::treebox::tooltip_window'
class tooltip_window;
^
11 warnings and 3 errors generated.
make: *** [../../source/gui/widgets/treebox.o] Error 1
clang++ -g -c ../../source/gui/widgets/widget.cpp -o ../../source/gui/widgets/widget.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/widget.cpp:12:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
2 errors generated.
make: *** [../../source/gui/widgets/widget.o] Error 1
clang++ -g -c ../../source/gui/widgets/skeletons/text_editor.cpp -o ../../source/gui/widgets/skeletons/text_editor.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
In file included from ../../include/nana/gui/widgets/scroll.hpp:15:
In file included from ../../include/nana/gui/widgets/widget.hpp:18:
../../include/nana/internationalization.hpp:137:30: error: only virtual member functions can be marked 'override'
nana::string eval() const override
^~~~~~~~
../../include/nana/internationalization.hpp:144:44: error: only virtual member functions can be marked 'override'
std::unique_ptr<eval_arg> clone() const override
^~~~~~~~
../../source/gui/widgets/skeletons/text_editor.cpp:667:16: warning: 'take_lines' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
std::size_t take_lines() const
^
../../source/gui/widgets/skeletons/text_editor.cpp:246:24: note: overridden virtual function is here
virtual std::size_t take_lines() const = 0;
^
../../source/gui/widgets/skeletons/text_editor.cpp:676:16: warning: 'take_lines' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
std::size_t take_lines(std::size_t pos) const
^
../../source/gui/widgets/skeletons/text_editor.cpp:248:24: note: overridden virtual function is here
virtual std::size_t take_lines(std::size_t pos) const = 0;
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:183:10: warning: 'attached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void attached(widget_reference widget, graph_reference graph)
^
../../include/nana/gui/widgets/widget.hpp:209:17: note: in instantiation of template class 'nana::drawerbase::scroll::trigger<true>' requested here
DrawerTrigger trigger_;
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/skeletons/text_editor.cpp:2031:12: note: in instantiation of template class 'nana::scroll<true>' requested here
if(vert && attributes_.vscroll)
^
../../include/nana/gui/detail/drawer.hpp:34:16: note: overridden virtual function is here
virtual void attached(widget_reference, graph_reference); //none-const
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:193:10: warning: 'detached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void detached()
^
../../include/nana/gui/detail/drawer.hpp:35:16: note: overridden virtual function is here
virtual void detached(); //none-const
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:198:10: warning: 'refresh' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void refresh(graph_reference graph)
^
../../include/nana/gui/detail/drawer.hpp:38:16: note: overridden virtual function is here
virtual void refresh(graph_reference);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:216:10: warning: 'mouse_move' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:46:16: note: overridden virtual function is here
virtual void mouse_move(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:243:10: warning: 'mouse_down' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_down(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:48:16: note: overridden virtual function is here
virtual void mouse_down(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:278:10: warning: 'mouse_up' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_up(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:49:16: note: overridden virtual function is here
virtual void mouse_up(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:290:10: warning: 'mouse_leave' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_leave(graph_reference graph, const arg_mouse&)
^
../../include/nana/gui/detail/drawer.hpp:47:16: note: overridden virtual function is here
virtual void mouse_leave(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:299:10: warning: 'mouse_wheel' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_wheel(graph_reference graph, const arg_wheel& arg)
^
../../include/nana/gui/detail/drawer.hpp:50:16: note: overridden virtual function is here
virtual void mouse_wheel(graph_reference, const arg_wheel&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
In file included from ../../include/nana/gui/widgets/scroll.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<true>, nana::drawerbase::scroll::scroll_events<true> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/skeletons/text_editor.cpp:2031:12: note: in instantiation of template class 'nana::scroll<true>' requested here
if(vert && attributes_.vscroll)
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:183:10: warning: 'attached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void attached(widget_reference widget, graph_reference graph)
^
../../include/nana/gui/widgets/widget.hpp:209:17: note: in instantiation of template class 'nana::drawerbase::scroll::trigger<false>' requested here
DrawerTrigger trigger_;
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<false>, nana::drawerbase::scroll::scroll_events<false> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/skeletons/text_editor.cpp:2064:51: note: in instantiation of template class 'nana::scroll<false>' requested here
auto sv = static_cast<int>(attributes_.hscroll->value());
^
../../include/nana/gui/detail/drawer.hpp:34:16: note: overridden virtual function is here
virtual void attached(widget_reference, graph_reference); //none-const
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:193:10: warning: 'detached' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void detached()
^
../../include/nana/gui/detail/drawer.hpp:35:16: note: overridden virtual function is here
virtual void detached(); //none-const
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:198:10: warning: 'refresh' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void refresh(graph_reference graph)
^
../../include/nana/gui/detail/drawer.hpp:38:16: note: overridden virtual function is here
virtual void refresh(graph_reference);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:216:10: warning: 'mouse_move' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_move(graph_reference graph, const ::nana::arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:46:16: note: overridden virtual function is here
virtual void mouse_move(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:243:10: warning: 'mouse_down' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_down(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:48:16: note: overridden virtual function is here
virtual void mouse_down(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:278:10: warning: 'mouse_up' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_up(graph_reference graph, const arg_mouse& arg)
^
../../include/nana/gui/detail/drawer.hpp:49:16: note: overridden virtual function is here
virtual void mouse_up(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:290:10: warning: 'mouse_leave' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_leave(graph_reference graph, const arg_mouse&)
^
../../include/nana/gui/detail/drawer.hpp:47:16: note: overridden virtual function is here
virtual void mouse_leave(graph_reference, const arg_mouse&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
../../include/nana/gui/widgets/scroll.hpp:299:10: warning: 'mouse_wheel' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
void mouse_wheel(graph_reference graph, const arg_wheel& arg)
^
../../include/nana/gui/detail/drawer.hpp:50:16: note: overridden virtual function is here
virtual void mouse_wheel(graph_reference, const arg_wheel&);
^
In file included from ../../source/gui/widgets/skeletons/text_editor.cpp:13:
In file included from ../../include/nana/gui/widgets/skeletons/text_editor.hpp:17:
In file included from ../../include/nana/gui/widgets/scroll.hpp:15:
../../include/nana/gui/widgets/widget.hpp:203:19: warning: '_m_get_general_events' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
general_events& _m_get_general_events() const
^
../../include/nana/gui/widgets/scroll.hpp:332:12: note: in instantiation of template class 'nana::widget_object<nana::category::widget_tag, nana::drawerbase::scroll::trigger<false>, nana::drawerbase::scroll::scroll_events<false> >' requested here
: public widget_object<category::widget_tag, drawerbase::scroll::trigger<Vertical>, drawerbase::scroll::scroll_events<Vertical>>
^
../../source/gui/widgets/skeletons/text_editor.cpp:2064:51: note: in instantiation of template class 'nana::scroll<false>' requested here
auto sv = static_cast<int>(attributes_.hscroll->value());
^
../../include/nana/gui/widgets/widget.hpp:92:27: note: overridden virtual function is here
virtual general_events& _m_get_general_events() const = 0;
^
20 warnings and 2 errors generated.
make: *** [../../source/gui/widgets/skeletons/text_editor.o] Error 1
clang++ -g -c ../../source/paint/image.cpp -o ../../source/paint/image.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/paint/image.cpp:24:
../../include/nana/paint/detail/image_bmp.hpp:97:42: warning: absolute value function 'abs' given an argument of type 'long' but has parameter of type 'int' which may cause truncation of value [-Wabsolute-value]
const std::size_t height_pixels = abs(info->bmiHeader.biHeight);
^
../../include/nana/paint/detail/image_bmp.hpp:97:42: note: use function 'std::abs' instead
const std::size_t height_pixels = abs(info->bmiHeader.biHeight);
^~~
std::abs
In file included from ../../source/paint/image.cpp:25:
../../include/nana/paint/detail/image_ico.hpp:35:15: warning: private field 'is_ico_' is not used [-Wunused-private-field]
const bool is_ico_;
^
2 warnings generated.
make: Target `libnana.a' not remade because of errors.
????
Hi !
There is a *.suo file in the repository. We need it? If this is just an small error it can be included in .gitignore. Anyway it can be good to have an .gitignore. There are many examples in:
https://github.com/github/gitignore
and this is what I use:
https://github.com/qPCR4vir/myNana/blob/master/.gitignore
Also, you recommend to build the static lib in:
NanaPath/build/bin/IDEName
I think this dir and any other temporal dir for compiler/link need to be in .ignore too... etc. Only the original code have to be under source control, to help "pushing" and "pulling"
Please use below code to reproduce the issue.
#include <nana/gui.hpp>
#include <nana/gui/widgets/panel.hpp>
#include <nana/gui/widgets/textbox.hpp>
using namespace nana;
int main()
{
using namespace nana;
form fm(API::make_center(500, 300));
fm.caption(L"tabstop test");
panel<true> panel(fm, rectangle(fm.size()));
textbox txt(panel, rectangle{50, 50, 100, 30});
txt.multi_lines(false);
txt.caption(L"aaaa");
API::eat_tabstop(txt, false);
fm.events().resized([&] (const arg_resized& arg) {
auto size = panel.size();
panel.move(arg.width - size.width, arg.height - size.height);
});
txt.focus();
fm.show();
exec();
}
After the form is shown, resize the dialog and see position of textbox's caret.
When using the textbox on Linux, nana inserts squares in the text when pressing arrow keys, shift, ctrl, capslock, insert, home, etc...
Shift also causes some other issues, as entering shift+1 ( !, the exclamation) twice erases a portion of the text, as if the text got selected then replaced.
Please see discussion here:
qPCR4vir/nana-docs#2 (comment)
Hi, I noticed pressing mouse button outside of widget area pushes the button widget.
Below are the steps to reproduce it.
Initial screen after the startup of program.
Last column reoreded to left-most, still correct.
Column widths shrinked by dragging header borders. still looking alright.
(sometimes column reorederd unexpectedly after dragend timing if I dragged the column border excessively but that is another matter...)
Bottom row selected.
Please pay attension to the bottom row since middle and last columns rendered improperly.
I thought some of these were Clang bugs, but GCC 4.8 most of the same errors:
clang++ -g -c ../../source/detail/platform_spec_selector.cpp -o ../../source/detail/platform_spec_selector.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/detail/platform_spec_selector.cpp:21:
../../source/detail/linux_X11/platform_spec.cpp:379:21: error: expected ')'
rgb = ((((color >> 16) & 0xFF) * 31 / 255) << 11) |
^
../../source/detail/linux_X11/platform_spec.cpp:379:14: note: to match this '('
rgb = ((((color >> 16) & 0xFF) * 31 / 255) << 11) |
^
../../source/detail/linux_X11/platform_spec.cpp:379:28: error: cannot take the address of an rvalue of type 'int'
rgb = ((((color >> 16) & 0xFF) * 31 / 255) << 11) |
^ ~~~~
../../source/detail/linux_X11/platform_spec.cpp:380:16: error: expected ')'
((((color >> 8) & 0xFF) * 63 / 255) << 5) |
^
../../source/detail/linux_X11/platform_spec.cpp:380:9: note: to match this '('
((((color >> 8) & 0xFF) * 63 / 255) << 5) |
^
../../source/detail/linux_X11/platform_spec.cpp:380:22: error: cannot take the address of an rvalue of type 'int'
((((color >> 8) & 0xFF) * 63 / 255) << 5) |
^ ~~~~
../../source/detail/linux_X11/platform_spec.cpp:381:15: error: expected ')'
(color & 0xFF) * 31 / 255;
^
../../source/detail/linux_X11/platform_spec.cpp:381:6: note: to match this '('
(color & 0xFF) * 31 / 255;
^
../../source/detail/linux_X11/platform_spec.cpp:381:21: error: indirection requires pointer operand ('int' invalid)
(color & 0xFF) * 31 / 255;
^ ~~
../../source/detail/linux_X11/platform_spec.cpp:798:36: error: too many arguments to function call, expected 1, have 2
addr->graph.make(caret_sz.width, caret_sz.height);
~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~
../../include/nana/paint/graphics.hpp:88:4: note: 'make' declared here
void make(const ::nana::size&); ///< Creates a bitmap resource that size is width by height in pixel
^
In file included from ../../source/detail/platform_spec_selector.cpp:21:
../../source/detail/linux_X11/platform_spec.cpp:799:15: error: no matching member function for call to 'rectangle'
addr->graph.rectangle(0x0, true);
~~~~~~~~~~~~^~~~~~~~~
../../include/nana/paint/graphics.hpp:155:9: note: candidate function not viable: no known conversion from 'bool' to 'const nana::color' for 2nd argument
void rectangle(bool solid, const color&);
^
../../include/nana/paint/graphics.hpp:156:9: note: candidate function not viable: no known conversion from 'int' to 'const ::nana::rectangle' for 1st argument
void rectangle(const ::nana::rectangle&, bool solid);
^
../../include/nana/paint/graphics.hpp:154:9: note: candidate function not viable: requires single argument 'solid', but 2 arguments were provided
void rectangle(bool solid);
^
../../include/nana/paint/graphics.hpp:157:9: note: candidate function not viable: requires 3 arguments, but 2 were provided
void rectangle(const ::nana::rectangle&, bool solid, const color&);
^
In file included from ../../source/detail/platform_spec_selector.cpp:21:
../../source/detail/linux_X11/platform_spec.cpp:800:40: error: too many arguments to function call, expected 1, have 2
addr->rev_graph.make(caret_sz.width, caret_sz.height);
~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~
../../include/nana/paint/graphics.hpp:88:4: note: 'make' declared here
void make(const ::nana::size&); ///< Creates a bitmap resource that size is width by height in pixel
^
In file included from ../../source/detail/platform_spec_selector.cpp:21:
../../source/detail/linux_X11/platform_spec.cpp:1131:32: error: too many arguments to function call, expected 1, have 2
graph.make(img.size().width, img.size().height);
~~~~~~~~~~ ^~~~~~~~~~~~~~~~~
../../include/nana/paint/graphics.hpp:88:4: note: 'make' declared here
void make(const ::nana::size&); ///< Creates a bitmap resource that size is width by height in pixel
^
10 errors generated.
make: *** [../../source/detail/platform_spec_selector.o] Error 1
clang++ -g -c ../../source/gui/msgbox.cpp -o ../../source/gui/msgbox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/msgbox.cpp:13:
In file included from ../../include/nana/gui.hpp:1:
In file included from ../../include/nana/gui/wvl.hpp:20:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
../../include/nana/gui/widgets/widget.hpp:352:10: warning: 'handle' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
window handle() const
^
../../include/nana/gui/widgets/form.hpp:37:21: note: in instantiation of template class 'nana::widget_object<nana::category::root_tag, nana::drawerbase::form::trigger, nana::detail::events_root_extension, nana::widget_colors>' requested here
class form: public widget_object<category::root_tag, drawerbase::form::trigger, detail::events_root_extension>
^
../../include/nana/gui/widgets/widget.hpp:32:18: note: overridden virtual function is here
virtual window handle() const = 0; ///< Returns the handle of window, returns 0 if window is not created.
^
../../include/nana/gui/widgets/widget.hpp:352:10: warning: 'handle' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
window handle() const
^
../../include/nana/gui/widgets/float_listbox.hpp:81:12: note: in instantiation of template class 'nana::widget_object<nana::category::root_tag, nana::drawerbase::float_listbox::trigger, nana::general_events, nana::widget_colors>' requested here
: public widget_object<category::root_tag, drawerbase::float_listbox::trigger>
^
../../include/nana/gui/widgets/widget.hpp:32:18: note: overridden virtual function is here
virtual window handle() const = 0; ///< Returns the handle of window, returns 0 if window is not created.
^
../../source/gui/msgbox.cpp:45:12: error: no matching member function for call to 'rectangle'
graph.rectangle(nana::rectangle{0, 0, graph.width(), graph.height() - 50}, 0xFFFFFF, true);
~~~~~~^~~~~~~~~
../../include/nana/paint/graphics.hpp:157:9: note: candidate function not viable: no known conversion from 'bool' to 'const nana::color' for 3rd argument
void rectangle(const ::nana::rectangle&, bool solid, const color&);
^
../../include/nana/paint/graphics.hpp:155:9: note: candidate function not viable: requires 2 arguments, but 3 were provided
void rectangle(bool solid, const color&);
^
../../include/nana/paint/graphics.hpp:156:9: note: candidate function not viable: requires 2 arguments, but 3 were provided
void rectangle(const ::nana::rectangle&, bool solid);
^
../../include/nana/paint/graphics.hpp:154:9: note: candidate function not viable: requires single argument 'solid', but 3 arguments were provided
void rectangle(bool solid);
^
../../source/gui/msgbox.cpp:301:21: error: too many arguments to function call, expected 1, have 2
ico_.make(32, 32);
~~~~~~~~~ ^~
../../include/nana/paint/graphics.hpp:88:4: note: 'make' declared here
void make(const ::nana::size&); ///< Creates a bitmap resource that size is width by height in pixel
^
In file included from ../../source/gui/msgbox.cpp:13:
In file included from ../../include/nana/gui.hpp:1:
In file included from ../../include/nana/gui/wvl.hpp:20:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
../../include/nana/gui/widgets/widget.hpp:269:10: warning: 'handle' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
window handle() const
^
../../include/nana/gui/widgets/panel.hpp:38:12: note: in instantiation of template class 'nana::widget_object<nana::category::lite_widget_tag, nana::drawerbase::panel::drawer, nana::general_events, nana::widget_colors>' requested here
: public widget_object<typename std::conditional<HasBackground, category::widget_tag, category::lite_widget_tag>::type,
^
../../source/gui/msgbox.cpp:557:24: note: in instantiation of template class 'nana::panel<false>' requested here
::nana::panel<false> dock;
^
../../include/nana/gui/widgets/widget.hpp:32:18: note: overridden virtual function is here
virtual window handle() const = 0; ///< Returns the handle of window, returns 0 if window is not created.
^
3 warnings and 2 errors generated.
make: *** [../../source/gui/msgbox.o] Error 1
clang++ -g -c ../../source/gui/screen.cpp -o ../../source/gui/screen.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/gui/screen.cpp:50:5: error: use of undeclared identifier 'position_'
position_.x = position_.y = 0;
^
../../source/gui/screen.cpp:50:19: error: use of undeclared identifier 'position_'
position_.x = position_.y = 0;
^
../../source/gui/screen.cpp:51:5: error: use of undeclared identifier 'size_'
size_ = detail::native_interface::primary_monitor_size();
^
3 errors generated.
make: *** [../../source/gui/screen.o] Error 1
clang++ -g -c ../../source/gui/detail/bedrock_pi.cpp -o ../../source/gui/detail/bedrock_pi.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
In file included from ../../source/gui/detail/bedrock_pi.cpp:20:
In file included from ../../include/nana/gui/wvl.hpp:19:
../../include/nana/gui/screen.hpp:28:29: error: too few arguments provided to function-like macro invocation
virtual std::size_t index() const = 0;
^
/usr/include/X11/Xos.h:67:12: note: macro 'index' defined here
# define index(s,c) (strchr((s),(c)))
^
In file included from ../../source/gui/detail/bedrock_pi.cpp:20:
In file included from ../../include/nana/gui/wvl.hpp:19:
../../include/nana/gui/screen.hpp:28:3: error: 'virtual' can only appear on non-static member functions
virtual std::size_t index() const = 0;
^
../../include/nana/gui/screen.hpp:28:28: error: expected ';' at end of declaration list
virtual std::size_t index() const = 0;
^
;
In file included from ../../source/gui/detail/bedrock_pi.cpp:20:
In file included from ../../include/nana/gui/wvl.hpp:20:
In file included from ../../include/nana/gui/widgets/form.hpp:16:
../../include/nana/gui/widgets/widget.hpp:352:10: warning: 'handle' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
window handle() const
^
../../include/nana/gui/widgets/form.hpp:37:21: note: in instantiation of template class 'nana::widget_object<nana::category::root_tag, nana::drawerbase::form::trigger, nana::detail::events_root_extension, nana::widget_colors>' requested here
class form: public widget_object<category::root_tag, drawerbase::form::trigger, detail::events_root_extension>
^
../../include/nana/gui/widgets/widget.hpp:32:18: note: overridden virtual function is here
virtual window handle() const = 0; ///< Returns the handle of window, returns 0 if window is not created.
^
1 warning and 3 errors generated.
make: *** [../../source/gui/detail/bedrock_pi.o] Error 1
clang++ -g -c ../../source/gui/detail/window_manager.cpp -o ../../source/gui/detail/window_manager.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/gui/detail/window_manager.cpp:682:48: error: too few arguments to function call, expected 2, have 1
wd->drawer.map(reinterpret_cast<window>(wd));
~~~~~~~~~~~~~~ ^
../../include/nana/gui/detail/drawer.hpp:113:4: note: 'map' declared here
void map(window, bool forced); //Copy the root buffer to screen
^
1 error generated.
make: *** [../../source/gui/detail/window_manager.o] Error 1
clang++ -g -c ../../source/gui/widgets/listbox.cpp -o ../../source/gui/widgets/listbox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/gui/widgets/listbox.cpp:1197:21: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy{ess_, pos}, ck};
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:1251:21: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy(ess_, i), sel };
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:1378:21: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy(ess_, index_pair(next_selected.cat, absolute(next_selected))), true };
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:1401:19: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy(ess_, index_pair(cat_pos, item_pos)), false };
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:1485:20: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy(ess_, index_pair(cat_pos, item_pos)), false };
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:1588:20: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy(ess_, index_pair(cat, index)), ck};
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:1626:20: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy(ess_, pos), sel };
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:3015:22: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{item_proxy{essence_, last_selected}, sel};
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
../../source/gui/widgets/listbox.cpp:3037:22: error: no matching constructor for initialization of 'nana::arg_listbox'
arg_listbox arg{ item_proxy{ essence_, abs_pos }, item_ptr->flags.checked };
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../include/nana/gui/widgets/listbox.hpp:424:3: note: candidate constructor not viable: expects an l-value for 1st argument
arg_listbox(drawerbase::listbox::item_proxy&, bool selected);
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
struct arg_listbox
^
../../include/nana/gui/widgets/listbox.hpp:418:9: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 2 were provided
9 errors generated.
make: *** [../../source/gui/widgets/listbox.o] Error 1
clang++ -g -c ../../source/gui/widgets/treebox.cpp -o ../../source/gui/widgets/treebox.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/gui/widgets/treebox.cpp:630:32: error: allocation of incomplete type 'nana::drawerbase::treebox::tooltip_window'
node_state.tooltip = new tooltip_window(data.widget_ptr->handle(), text_r);
^~~~~~~~~~~~~~
../../source/gui/widgets/treebox.cpp:77:10: note: forward declaration of 'nana::drawerbase::treebox::tooltip_window'
class tooltip_window;
^
../../source/gui/widgets/treebox.cpp:660:7: warning: deleting pointer to incomplete type 'nana::drawerbase::treebox::tooltip_window' may cause undefined behavior [-Wdelete-incomplete]
delete x;
^ ~
../../source/gui/widgets/treebox.cpp:77:10: note: forward declaration of 'nana::drawerbase::treebox::tooltip_window'
class tooltip_window;
^
In file included from ../../source/gui/widgets/treebox.cpp:12:
In file included from ../../include/nana/gui/widgets/treebox.hpp:20:
../../include/nana/gui/widgets/widget.hpp:352:10: warning: 'handle' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
window handle() const
^
../../source/gui/widgets/treebox.cpp:1443:14: note: in instantiation of template class 'nana::widget_object<nana::category::root_tag, nana::drawerbase::treebox::tlwnd_drawer, nana::general_events, nana::widget_colors>' requested here
: public widget_object<category::root_tag, tlwnd_drawer>
^
../../include/nana/gui/widgets/widget.hpp:32:18: note: overridden virtual function is here
virtual window handle() const = 0; ///< Returns the handle of window, returns 0 if window is not created.
^
2 warnings and 1 error generated.
make: *** [../../source/gui/widgets/treebox.o] Error 1
clang++ -g -c ../../source/paint/gadget.cpp -o ../../source/paint/gadget.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/paint/gadget.cpp:102:60: error: non-constant-expression cannot be narrowed from type 'unsigned long' to 'unsigned int' in initializer list [-Wc++11-narrowing]
graph.rectangle(rectangle{ ps[10].x + 1, ps[10].y + 1, (gap << 1) + thickness - 2, thickness - 2 }, true);
^~~~~~~~~~~~~~~~~~~~~~~~~~
../../source/paint/gadget.cpp:102:60: note: insert an explicit cast to silence this issue
graph.rectangle(rectangle{ ps[10].x + 1, ps[10].y + 1, (gap << 1) + thickness - 2, thickness - 2 }, true);
^~~~~~~~~~~~~~~~~~~~~~~~~~
static_cast<unsigned int>()
../../source/paint/gadget.cpp:102:88: error: non-constant-expression cannot be narrowed from type 'unsigned long' to 'unsigned int' in initializer list [-Wc++11-narrowing]
graph.rectangle(rectangle{ ps[10].x + 1, ps[10].y + 1, (gap << 1) + thickness - 2, thickness - 2 }, true);
^~~~~~~~~~~~~
../../source/paint/gadget.cpp:102:88: note: insert an explicit cast to silence this issue
graph.rectangle(rectangle{ ps[10].x + 1, ps[10].y + 1, (gap << 1) + thickness - 2, thickness - 2 }, true);
^~~~~~~~~~~~~
static_cast<unsigned int>( )
../../source/paint/gadget.cpp:103:58: error: non-constant-expression cannot be narrowed from type 'unsigned long' to 'unsigned int' in initializer list [-Wc++11-narrowing]
graph.rectangle(rectangle{ ps[0].x + 1, ps[0].y + 1, thickness - 2, (gap << 1) + thickness - 2 }, true);
^~~~~~~~~~~~~
../../source/paint/gadget.cpp:103:58: note: insert an explicit cast to silence this issue
graph.rectangle(rectangle{ ps[0].x + 1, ps[0].y + 1, thickness - 2, (gap << 1) + thickness - 2 }, true);
^~~~~~~~~~~~~
static_cast<unsigned int>( )
../../source/paint/gadget.cpp:103:73: error: non-constant-expression cannot be narrowed from type 'unsigned long' to 'unsigned int' in initializer list [-Wc++11-narrowing]
graph.rectangle(rectangle{ ps[0].x + 1, ps[0].y + 1, thickness - 2, (gap << 1) + thickness - 2 }, true);
^~~~~~~~~~~~~~~~~~~~~~~~~~
../../source/paint/gadget.cpp:103:73: note: insert an explicit cast to silence this issue
graph.rectangle(rectangle{ ps[0].x + 1, ps[0].y + 1, thickness - 2, (gap << 1) + thickness - 2 }, true);
^~~~~~~~~~~~~~~~~~~~~~~~~~
static_cast<unsigned int>()
4 errors generated.
make: *** [../../source/paint/gadget.o] Error 1
clang++ -g -c ../../source/paint/graphics.cpp -o ../../source/paint/graphics.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/paint/graphics.cpp:1012:5: error: use of undeclared identifier 'x'
x, y);
^
../../source/paint/graphics.cpp:1012:8: error: use of undeclared identifier 'y'
x, y);
^
../../source/paint/graphics.cpp:1013:32: error: use of undeclared identifier 'x'
handle_->line_begin_pos.x = x;
^
../../source/paint/graphics.cpp:1014:32: error: use of undeclared identifier 'y'
handle_->line_begin_pos.y = y;
^
../../source/paint/graphics.cpp:1078:39: error: reference to non-static member function must be called; did you mean to call it with no arguments?
double deltapx = double(vertical ? height : width);
^~~~~~
()
../../source/paint/graphics.cpp:1078:48: error: reference to non-static member function must be called; did you mean to call it with no arguments?
double deltapx = double(vertical ? height : width);
^~~~~
()
../../source/paint/graphics.cpp:1079:11: error: redefinition of 'r' with a different type: 'double' vs 'const ::nana::rectangle &'
double r, g, b;
^
../../source/paint/graphics.cpp:1067:61: note: previous definition is here
void graphics::gradual_rectangle(const ::nana::rectangle& r, const ::nana::color& from, const ::nana::color& to, bool vertical)
^
../../source/paint/graphics.cpp:1080:40: error: no viable overloaded '='
const double delta_r = (to.r() - (r = from.r())) / deltapx;
~ ^ ~~~~~~~~
../../include/nana/basic_types.hpp:400:9: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const ::nana::rectangle', but method is not marked const
struct rectangle
^
../../include/nana/basic_types.hpp:410:14: note: candidate function not viable: 'this' argument has type 'const ::nana::rectangle', but method is not marked const
rectangle& operator=(const point&);
^
../../include/nana/basic_types.hpp:411:14: note: candidate function not viable: 'this' argument has type 'const ::nana::rectangle', but method is not marked const
rectangle& operator=(const size&);
^
../../include/nana/basic_types.hpp:400:9: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const ::nana::rectangle', but method is not marked const
struct rectangle
^
../../source/paint/graphics.cpp:1084:27: error: cannot convert 'const ::nana::rectangle' to 'int' without a conversion operator
unsigned last_color = (int(r) << 16) | (int(g) << 8) | int(b);
^~~~~
../../source/paint/graphics.cpp:1087:21: error: reference to type 'const ::nana::color' could not bind to an lvalue of type 'unsigned int'
handle_->fgcolor(last_color);
^~~~~~~~~~
../../include/nana/detail/linux_X11/platform_spec.hpp:108:36: note: passing argument to parameter here
void fgcolor(const ::nana::color&); //deprecated
^
../../source/paint/graphics.cpp:1088:45: error: use of undeclared identifier 'y'
const int endpos = deltapx + (vertical ? y : x);
^
../../source/paint/graphics.cpp:1088:49: error: use of undeclared identifier 'x'
const int endpos = deltapx + (vertical ? y : x);
^
../../source/paint/graphics.cpp:1093:15: error: use of undeclared identifier 'x'
int x1 = x, x2 = x + static_cast<int>(width);
^
../../source/paint/graphics.cpp:1093:23: error: use of undeclared identifier 'x'
int x1 = x, x2 = x + static_cast<int>(width);
^
../../source/paint/graphics.cpp:1093:44: error: reference to non-static member function must be called; did you mean to call it with no arguments?
int x1 = x, x2 = x + static_cast<int>(width);
^~~~~
()
../../source/paint/graphics.cpp:1094:13: error: use of undeclared identifier 'y'
for (; y < endpos; ++y)
^
../../source/paint/graphics.cpp:1094:27: error: use of undeclared identifier 'y'
for (; y < endpos; ++y)
^
../../source/paint/graphics.cpp:1096:64: error: use of undeclared identifier 'y'
::XDrawLine(disp, handle_->pixmap, handle_->context, x1, y, x2, y);
^
../../source/paint/graphics.cpp:1096:71: error: use of undeclared identifier 'y'
::XDrawLine(disp, handle_->pixmap, handle_->context, x1, y, x2, y);
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
make: *** [../../source/paint/graphics.o] Error 1
clang++ -g -c ../../source/paint/detail/native_paint_interface.cpp -o ../../source/paint/detail/native_paint_interface.o -I../../include -I/usr/include/freetype2 -std=c++0x -Wall
../../source/paint/detail/native_paint_interface.cpp:194:54: error: use of undeclared identifier 'x'
XftDrawGlyphs(dw->xftdraw, &(dw->xft_fgcolor), fs, x, y + fs->ascent, glyphs_ptr.get(), len);
^
../../source/paint/detail/native_paint_interface.cpp:194:57: error: use of undeclared identifier 'y'
XftDrawGlyphs(dw->xftdraw, &(dw->xft_fgcolor), fs, x, y + fs->ascent, glyphs_ptr.get(), len);
^
2 errors generated.
make: *** [../../source/paint/detail/native_paint_interface.o] Error 1
In CMakeLists.txt, we detect environment and copy them into config.hpp.
In fact, we can use some compiler detection libraries(such as boost/predef) to do this job. We can easily detect compiler versions in cpp files.
eg.
#if defined(__MINGW__) && __GNUC_MINOR__ < 8
#define NANA_THREAD_NOT_SUPPORTED
#endif
The discussion site in nanopro have some problems.
The full list is not printed:
Start Discussion
Loading discussion list...
And the same for the last entry:
posted by:
Invalid Date
write a comment
Hi !
It could be good to add a simple git tag in this first commit.
(learning GitHub)
NANA_THREAD_NOT_SUPPORTED is hard coded in CMakeLists.txt to ON. I think it should be OFF by default esp. for non-gui users of cmake. Better yet this could be automatically tested. I followed the example given in this SO post and wrote a test for this:
option(NANA_THREAD_NOT_SUPPORTED "Use this flag if MinGW version is older than 4.8.1" OFF)
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.8.1")
option(NANA_THREAD_NOT_SUPPORTED "Use this flag if MinGW version is older than 4.8.1" ON)
endif()
endif()
With API::eat_tabstop(widget, false), I can change the focus of widgets by pressing tab key.
Here is working example code.
#include <nana/gui.hpp>
#include <nana/gui/widgets/textbox.hpp>
using namespace nana;
int main()
{
using namespace nana;
form fm(API::make_center(500, 300));
fm.caption(L"tabstop test");
textbox txt(fm, rectangle{50, 50, 100, 30});
txt.multi_lines(false);
txt.caption(L"aaaa");
textbox txt2(fm, rectangle(50, 90, 200, 200));
txt2.caption(L"aaaa\nbbbb\ncccc\n");
API::eat_tabstop(txt, false);
API::eat_tabstop(txt2, false);
fm.show();
exec();
}
But when there's only one textbox widget in a form, pressing tab key shows different result.
Please test below code.
#include <nana/gui.hpp>
#include <nana/gui/widgets/textbox.hpp>
using namespace nana;
int main()
{
using namespace nana;
form fm(API::make_center(500, 300));
fm.caption(L"tabstop test");
textbox txt(fm, rectangle{50, 50, 100, 30});
txt.multi_lines(false);
txt.caption(L"aaaa");
API::eat_tabstop(txt, false);
fm.show();
exec();
}
With above code, the textbox widget eats the tab and put it into its text editor, but that is different from expected behavior.
When a vertical slider is used, it seems to be inverted (0 at the top and vmax at the bottom).
I suppose it's a bug. I looked at the code but I didn't find a way to fix this.
Thanks to look at this
Currently, all the build files are hand-written. This is prone to error and maintenance hell as time passes. You should consider using Bakefile, which is based on the idea of pre-generating the build files. You run Bakefile on your computer, upload the generated files, and the user doesn't even know it exists.
It supports VS 2013 and GNU make. I can look into opening a PR for Code Blocks if desired.
Also, I'd be happy to contribute the build files if it's decided that this would be a good idea.
Below is the code and steps to reproduce the issue.
#include <nana/gui.hpp>
#include <nana/gui/widgets/menubar.hpp>
#include <nana/gui/widgets/textbox.hpp>
using namespace nana;
int main()
{
using namespace nana;
form fm(API::make_center(400, 500));
menubar mb;
mb.create(fm);
mb.push_back(L"&aaaaaa");
mb.push_back(L"&baaaaa");
mb.at(0).append(L"&1", [](menu::item_proxy& ip){
});
mb.at(0).append(L"&2", [](menu::item_proxy& ip){
});
mb.at(1).append(L"&1", [](menu::item_proxy& ip){
});
mb.at(1).append(L"&2", [](menu::item_proxy& ip){
});
textbox txt(fm, rectangle(10, 60, 200, 30));
fm.show();
exec();
}
I have the following build error:
FAILED: C:\alt\msys32\mingw32\bin\c++.exe -DNANA_ENABLE_PNG -DNANA_LIBPNG -DNANA_MINGW -DNANA_UNICODE -DNANA_WINDOWS -DPLATFORM_SPEC_HPP="<nana/detail/win32/platform_spec.hpp>" -DSTD_CODECVT_NOT_SUPPORTED -DUNICODE -D_UNICODE -Wall -I../include -std=gnu++14 -MMD -MT CMakeFiles/nana.dir/source/filesystem/filesystem.cpp.obj -MF CMakeFiles/nana.dir/source/filesystem/filesystem.cpp.obj.d -o CMakeFiles/nana.dir/source/filesystem/filesystem.cpp.obj -c ../source/filesystem/filesystem.cpp
../source/filesystem/filesystem.cpp: In function 'nana::experimental::filesystem::path nana::experimental::filesystem::current_path()':
../source/filesystem/filesystem.cpp:433:13: error: could not convert '(nana::char_t*)(& buf)' from 'nana::char_t* {aka wchar_t*}' to 'nana::experimental::filesystem::path'
return buf;
^
ninja: build stopped: subcommand failed.
An explicit cast is needed here:
git diff ../source/filesystem/filesystem.cpp
diff --git a/source/filesystem/filesystem.cpp b/source/filesystem/filesystem.cpp
index 51d70ff..215a587 100644
--- a/source/filesystem/filesystem.cpp
+++ b/source/filesystem/filesystem.cpp
@@ -430,7 +430,7 @@ namespace nana {
delete[] p;
return s;
}
- return buf;
+ return (nana::string) buf;
}
#elif defined(NANA_LINUX)
const char * s = ::getenv("PWD");
fixed it.
The program wont build using libc++ and clang on linux. I have problems with using libstdc++ on linux because of missing functions and errors when compiling it with clang.
Hi,
I am using form.events().key_press[release]()
to subscribe to keyboard events. Unfortunately when I press any key and hold it down I get lots and lots of key_press/key_release
calls - simply as OS is repeating key. This is not behavior I want and would expect - I need one press and one release.
Is this known issue? Or maybe this is by design
? Can I change the behavior?
I am running linux
> uname -a
Linux Archangel 4.5.0-1-ARCH #1 SMP PREEMPT Tue Mar 15 09:41:03 CET 2016 x86_64 GNU/Linux
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.