General Discussions
Discuss anything about this project.
134
Topics
592
Posts
3
Followers
Yes No
Hide topic messages
Yes No
Enable infinite scrolling
besh81 posted May 16 at 12:02 pm
Hi All,

I'm working on a new project and I would like to create a customizable layout where the user can show/hide, arrange, move, resize, etc ... several panels.
As reference example think to the MS Visual Studio editor.

I've worked a little with the DOCK field and it seems to be a good start but not yet complete.

Is there someone who use the DOCK field? If yes, what are your impr
3replies
32views
recent by besh81  ·  Sep 5 at 5:32 pm
Running the following simple demo and dragging the splitter bar to left (or right) close to the edge cause a crash due to the dock caption text renderer function

#include <nana/gui.hpp>
#include <nana/gui/place.hpp>
#include <nana/gui/widgets/button.hpp>

using namespace nana;

int main()
{
form fm{ API::make_center(600, 400) };

place p(fm);
p.div("margin=10 doc
1replies
16views
recent by besh81  ·  Sep 5 at 4:40 pm
Nana does not provide an arc drawing primitive, so we have to use the windows API directly. Something like this:

#include <cmath>
#include <nana/gui.hpp>

#include <windows.h>

/** Draw Arc of circle
@param[in] graph context
@param[in] x for conter, pixels 0 at left of window
@param[in] y for center, pixels 0 at top of window
@param[in] r radius, pixels

5d54260006bce.png
2replies
26views
recent by ravenspoint  ·  Aug 20 at 6:10 pm
mariusm posted Jun 25 at 2:28 pm
I need to make a function which open new form. In this form need to use mouse event and change label caption. Need this form to open many times.

bool openHold() {
using namespace nana::gui;

form fm(nana::rectangle(20, 20, 300, 300));
fm.caption(L"Hello World");

static label lm(fm);
lm.caption(L"Hello, world!");
button change(fm), quit(fm);
change.caption(L"Change
5replies
30views
recent by Error Flynn  ·  Jun 26 at 9:14 pm
mariusm posted Jun 22 at 2:21 pm
I want to build a program with system tray. For this I used WINAPI WinMain

When I close the program using LRESULT CALLBACK WindowProcedure I get this error: Nana.Gui detects a memory leaks in window_manager, 2 windows are not uninstalled

I try nana::API::exitall() but get error: 'exitall' : is not a member of 'nana::gui::API

I use Visual Studio 2008

2replies
11views
recent by mariusm  ·  Jun 25 at 2:22 pm
wertex posted Jun 12 at 9:39 am
Is it possible with nana API create textbox component, that support simple html and show small icons (like in telegram messages)?

0replies
10views
jinhao posted Apr 9 at 8:31 am
I find that many people use MinGW on Windows, but some redistros don't support standard library and COM well, and the configurations for MinGW and nana are complicated, therefore people often encounter the compiling/linkage errors.

So, I decided to create a simple IDE which would contain a MinGW and compiled nana. Also will provide a package management that can easy to update MinGW and nana,
5cac14971f5b0.png
28replies
250views
recent by _-LC-_  ·  May 10 at 2:14 pm
Hello, first of all thanks for your great work! :-)

For the listbox there are two models. Typically, if you have complicated data and you want to avoid data duplication and senseless back and forward conversions, you'd pick the shared_model.
The problem is that this model still forces you to do unnecessary conversions.
If you pick a shared_model and want to handle the container yoursel
2replies
35views
recent by _-LC-_  ·  May 7 at 11:35 am
Hello

I'm trying to compile nana-creator for linux. I downloaded the project and it includes a build/codeblocks_linux folder.

I opened that project and when I gave it to compile I get the following errors:

nana-creator/src/creator.cpp:179:9: error: could not convert ‘nana::filebox::operator()() const()’ from ‘std::vector<std::experimental::filesystem::v1::__cxx11:
3replies
28views
recent by Jbec  ·  May 5 at 5:37 pm
I'm using Windows 10 and the latest nana hotfix (tryied from a 1.6.2 compilating as well) and just building a form with nana::appearance(true, false, true, false, false, false, false) wont set it topmost. Is the floating the flag to set it topmost?
EDIT: Idk why I couldn't reproduce this... Sometimes it is topmost, sometimes not.

Also, related to the appearance but not to the floating:

15replies
121views
recent by eduardoroeder  ·  Apr 26 at 10:18 pm
@jinhao is parsing the first / or \ as a node intended? Because if you use the default xPath from other libraries it generates / as the first character from the root documents (eg pugixml).
I've seen the commit https://github.com/cnjinhao/nana/commit/5c50bd7a56291c4d818a00c7eff16c10b33ea317#diff-860264e5a2113a1a836ffd5e3cc74b11 but idk if this is intended. Can you check it out?

I've got a
3replies
23views
recent by eduardoroeder  ·  Apr 19 at 7:32 am
I have 20 radio buttons in a radio group. I would like to trigger a model recalculation when any of them are clicked. AFAIK, I now need to register an event handler for each radio button. It is not a huge amount of code, but it is very tedious. Would it be possible to register just one click handler for the entire group?

nana::radio_group rg( fm );
rg.Add( cb1 );
...
rg.events().click(
5replies
33views
recent by jinhao  ·  Apr 15 at 9:04 pm
Dev++ posted Apr 7 at 1:35 am
Ok, here's one that ive been holding off asking for a while.....
There is the graphics::blur method, but is there any way of creating a line or round rectangle (circle) with antialiasing?
Obviously I have googled and found algoritms such as
Xiaolin Wu's line algorithm
http://landkey.net/d/L/J/RF/WUCircle/Intro.txt.legacy.htm
https://stackoverflow.com/questions/37589165/drawing-an-
1replies
7views
recent by jinhao  ·  Apr 7 at 7:15 am
ravenspoint posted Mar 29 at 2:14 pm
What do the nana library designers consider the correct way to change the display when a widget is updated?

Some widgets, for example a label, automatically update their display when they are updated without the coder being required to do anything more.

myLabel.caption("New label");
Other widgets, for example a combox, do not update the display when they are updated. The code must add va
6replies
44views
recent by ravenspoint  ·  Mar 31 at 11:38 pm
A class derivated from nana::group does not have get_place, while a class derivated from nana::form does. This have a complication to not being able to access operator[] correctly.

Solution inside the derivated class to add child fields:

class tmp :nana::group{
nana::button btn;
void function (){
(*(group*)this)["buttonfield"] << btn;
}
}
Using this->operator
4replies
39views
recent by qPCR4vir  ·  Mar 30 at 10:05 am
Load more
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft