Search found 12055 matches

by doublemax
Tue Apr 24, 2018 6:40 am
Forum: C++ Development
Topic: trying to calc column cell clicked in wxListCtrl
Replies: 6
Views: 23

Re: trying to calc column cell clicked in wxListCtrl

I'm not sure how to get the window coordinates of each monitor. You can using wxDisplay. But you shouldn't have to do this. I'm just trying to narrow down where exactly the error is. Does this happen on all monitors? And which call returns wrong values, wxGetMousePosition or GetScreenPosition? I ha...
by doublemax
Tue Apr 24, 2018 5:46 am
Forum: C++ Development
Topic: trying to calc column cell clicked in wxListCtrl
Replies: 6
Views: 23

Re: trying to calc column cell clicked in wxListCtrl

What are the mouse coordinates you get from the click event?
What exactly is your monitor configuration (Position and size) ?
by doublemax
Tue Apr 24, 2018 5:30 am
Forum: C++ Development
Topic: trying to calc column cell clicked in wxListCtrl
Replies: 6
Views: 23

Re: trying to calc column cell clicked in wxListCtrl

Usually when you need this functionality, you already have the mouse coordinates in client space, from the mouse event. But there is also wxWindow::ScreenToClient(...) that does the conversion for you. At first glance the code looks ok, as usual: The debugger is your friend. Just single-step through...
by doublemax
Mon Apr 23, 2018 3:59 pm
Forum: C++ Development
Topic: wxGrid fixed rows
Replies: 4
Views: 37

Re: wxGrid fixed rows

Unless a volunteer for this feature drops from the sky, i don't expect this to happen. Ever. There was an alternative to wxGrid, wxAdvtable which supported multiline headers. I don't know if it also supported frozen rows/columns. If you really, really need this feature, check it out, but it hasn't b...
by doublemax
Mon Apr 23, 2018 12:53 pm
Forum: C++ Development
Topic: Refreseh wxDialog [SOLVED]
Replies: 12
Views: 106

Re: Refreseh wxDialog [SOLVED]

With your code there will always be two dialogs, the one outside the loop, and one inside. Try something like this: void Wall_MatFrame::OnMenuItem3Selected(wxCommandEvent& event) { bool loop = true; while (loop) { CreateProduct dialog(this); int ret = dialog.ShowModal(); if( ret != 1 ) loop = fa...
by doublemax
Mon Apr 23, 2018 12:28 pm
Forum: C++ Development
Topic: Refreseh wxDialog [SOLVED]
Replies: 12
Views: 106

Re: Refreseh wxDialog [SOLVED]

It's hard to tell without seeing the headers, but i'd guess that there are two different variables named "AnotherDialog", one in the main frame and one in the dialog.
by doublemax
Mon Apr 23, 2018 5:44 am
Forum: C++ Development
Topic: wxArray usage! [SOLVED]
Replies: 13
Views: 178

Re: wxArray usage! [SOLVED]

Is there a official milestone for replacing the old macro-based containers? There are lots of API still using them as input/output.

No, but i don't think they will be dropped anytime soon. If ever.
by doublemax
Mon Apr 23, 2018 5:42 am
Forum: C++ Development
Topic: help drawing this on device context
Replies: 17
Views: 192

Re: help drawing this on device context

Drawing with opengl seems to be pretty straight foward using glVertex2f That depends on which drawing operations you need. E.g. there is no function to draw text in OpenGL. So you need to find some code that does this for you. I just remembered this: https://forums.wxwidgets.org/viewtopic.php?p=962...
by doublemax
Mon Apr 23, 2018 5:35 am
Forum: C++ Development
Topic: help drawing this on device context
Replies: 17
Views: 192

Re: help drawing this on device context

Sorry, it's wxGLCanvas.
by doublemax
Mon Apr 23, 2018 4:59 am
Forum: C++ Development
Topic: help drawing this on device context
Replies: 17
Views: 192

Re: help drawing this on device context

Everydaydiesel wrote:Is it possible to draw with opengl inside of a wxwidgets wxPanel?
No, but you could convert the wxPanel to wxGLCanvas. But then you'd also have to replace all the wxDC based drawing with OpenGL commands.
by doublemax
Mon Apr 23, 2018 4:57 am
Forum: C++ Development
Topic: Refreseh wxDialog [SOLVED]
Replies: 12
Views: 106

Re: Refreseh wxDialog [SOLVED]

This can't work. There is only one thread, the code in Wall_MatFrame stops at the call to ShowModal() and only continues when the dialog is closed.

You can return any value from a dialog with wxDialog::EndModal( some_value )
by doublemax
Sun Apr 22, 2018 9:29 pm
Forum: C++ Development
Topic: Refreseh wxDialog [SOLVED]
Replies: 12
Views: 106

Re: Refreseh wxDialog [SOLVED]

Do I have to return something to my main program and let it create the dialog again or can I do this just inside the dialog code? You could do it inside the dialog using the methods i described earlier. But it's probably much easier to just return a special value to from ShowModal() and create a ne...
by doublemax
Sun Apr 22, 2018 8:53 pm
Forum: C++ Development
Topic: help drawing this on device context
Replies: 17
Views: 192

Re: help drawing this on device context

I linked gdiplus but the #if wxUSE_GRAPHICS_CONTEXT is grayed out. That means that your wxWidgets version was built without wxGraphicsContext support. Which wx version, platform and compiler are you using? wxGraphicsContext should be enabled on all major platforms by default now, if you're under Wi...
by doublemax
Sun Apr 22, 2018 8:37 pm
Forum: C++ Development
Topic: Refreseh wxDialog [SOLVED]
Replies: 12
Views: 106

Re: Refreseh wxDialog [SOLVED]

I think i misunderstood you, i thought you have a GUI where only parts are dynamically created based on some file. But i don't see anything like this in the code. If the whole dialog is depended on an external file, just create a completely new dialog (and destroy the old one). Modal dialogs should ...
by doublemax
Sun Apr 22, 2018 3:19 pm
Forum: Platform Related Issues
Topic: Themed wx Application question!
Replies: 5
Views: 134

Re: Themed wx Application question!

I don't think there is anything that can be done on wx side.

How does your skinning engine work? Do you hook into the paint routine of the windows?

My guess is that the issue is related to update rectangles. Try logging the update rectangles you receive, maybe it gives a hint.

Go to advanced search