Search found 118 matches

by JohnD
Mon Jan 31, 2011 3:23 pm
Forum: C++ Development
Topic: Creating a wx app when given a parent/top-level HWND?
Replies: 17
Views: 3776

That's the whole point, the host is unknown and there is no main(). So imagine I have a DLL project with an API method:

Code: Select all

//Application passes main window handle in
//This method initializes wxWidgets using this HWND
void Init(HWND handle);
by JohnD
Mon Jan 31, 2011 2:28 pm
Forum: C++ Development
Topic: Creating a wx app when given a parent/top-level HWND?
Replies: 17
Views: 3776

I think the question can be simplified to:

If I have a HWND passed in from someplace, can I use this as the basis for a wx-based application? I imagine there are a few scenarios where this could be the case, browser plugins are just one example.
by JohnD
Mon Jan 31, 2011 1:22 pm
Forum: C++ Development
Topic: Creating a wx app when given a parent/top-level HWND?
Replies: 17
Views: 3776

Creating a wx app when given a parent/top-level HWND?

We're looking at creating a browser plugin and our codebase uses wxWidgets. I can see a wxApp class doesn't require a HWND, and it seems that a TopFrame isn't a requirement for an application either? In a browser plugin (on Windows) you are essentially given a HWND to let you do your custom renderin...
by JohnD
Wed Jan 26, 2011 10:21 am
Forum: C++ Development
Topic: Combobox - can you get the selected string from the event?
Replies: 2
Views: 772

Combobox - can you get the selected string from the event?

A wxCommandEvent will tell me the selected index when I catch wxEVT_COMMAND_COMBOBOX_SELECTED events, but to get the string I need the control itself. Do I have to store a class member for the control or is there a way to do this from the event object only?
by JohnD
Sun Nov 07, 2010 12:02 am
Forum: C++ Development
Topic: Implementing a speech-bubble window
Replies: 4
Views: 971

Auria wrote:You could perhaps take a look at the "shaped" sample; but I'm not sure if this will work fine for you because the shaped window, when you pop it, might steal the focus
Not sure if focus is a problem or not, without trying. More than likely these windows need buttons like "close".
by JohnD
Sat Nov 06, 2010 6:58 pm
Forum: C++ Development
Topic: Implementing a speech-bubble window
Replies: 4
Views: 971

Implementing a speech-bubble window

We use wx in a C++ Windows app. How would one go about making a window that is not rectangular, such as a speech-bubble, or other irregular shape... like a "callout" window with a pointer pointing at some point on screen? Are there any built-in styles/controls for this kind of thing? The idea is kin...
by JohnD
Wed Sep 08, 2010 7:05 am
Forum: C++ Development
Topic: [2.8.10] Problem with wxRegKey on 64bit Windows
Replies: 5
Views: 1039

Here is the solution for your specific problem. Please note this works with Visual Studio Pro. :!: The catch: wxWidgets is open source and caters to most Operating Systems; and your problem is very Windows specific. Since you don't want to do it alone, hang out at the source ( Windows forums ) for ...
by JohnD
Tue Sep 07, 2010 7:12 am
Forum: C++ Development
Topic: [2.8.10] Problem with wxRegKey on 64bit Windows
Replies: 5
Views: 1039

It's a 32-bit app. The problem comes when it's run on a 64-bit version of Windows, certain keys are not being found, most notably HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProductId which is the Windows serial number. The whole thing is a bit confusing. I'd prefer not to totall...
by JohnD
Tue Sep 07, 2010 7:01 am
Forum: C++ Development
Topic: Don't suppose wx has any crypto functions?
Replies: 4
Views: 931

Re: Don't suppose wx has any crypto functions?

wxWidgets doesn't provide such functions. You can have a look to OpenSSL or Crypto++ . Thanks for those links. I also came across a library called Botan I'm looking for some easy non-GPL library that will let me encode text/data/file using a given key, so that the encrypted result can be decoded us...
by JohnD
Mon Sep 06, 2010 6:53 pm
Forum: C++ Development
Topic: [2.8.10] Problem with wxRegKey on 64bit Windows
Replies: 5
Views: 1039

[2.8.10] Problem with wxRegKey on 64bit Windows

As far as I can tell, wxRegKey makes no allowance for 32 bit apps running on 64 bit Windows, accessing redirected keys through WOW64 . Can anyone verify this, and tell me if I simply need to use plain Win32? For instance I see wxRegKey::Open calls Win32 function RegOpenKeyEx but lacks that one littl...
by JohnD
Sat Sep 04, 2010 9:29 am
Forum: C++ Development
Topic: Don't suppose wx has any crypto functions?
Replies: 4
Views: 931

Don't suppose wx has any crypto functions?

I'm looking for some easy non-GPL library that will let me encode text/data/file using a given key, so that the encrypted result can be decoded using the same key later. I just thought I'd check if wx might have anything before looking further afield. It doesn't need to be super-secure, we're only a...
by JohnD
Fri May 07, 2010 11:15 am
Forum: C++ Development
Topic: wxHtmlWindow: Failed to display HTML document in UTF-8
Replies: 0
Views: 511

wxHtmlWindow: Failed to display HTML document in UTF-8

I get this error when using this class to load a very simple HTML file. I remove all encoding and meta data since I don't know what HTML engine is used, but still get the same error. What's the right skeleton HTML doc to use with this class?
by JohnD
Wed Apr 28, 2010 6:27 pm
Forum: C++ Development
Topic: Does wx provide a way to set EXE version numbers?
Replies: 7
Views: 2073

I think I would just use a #define, except on Windows apps it's nice to set version in the EXE, it just looks a bit more like a 'real' app :) I guess I'll keep my RC file for ease of use, anyone know if there's a way to combine a #define with .rc, so the .rc file uses the #define? I know it's not a ...
by JohnD
Tue Apr 27, 2010 7:03 pm
Forum: C++ Development
Topic: Does wx provide a way to set EXE version numbers?
Replies: 7
Views: 2073

What's CVS got to do with my application being able to display "v2.3" on a Help->About dialog?
by JohnD
Tue Apr 27, 2010 4:42 pm
Forum: C++ Development
Topic: Does wx provide a way to set EXE version numbers?
Replies: 7
Views: 2073

Does wx provide a way to set EXE version numbers?

I'm doing this in a Windows .rc file right now, but does wx provide any similar facility? Apart from anything else, I'd like the app to be able to show the version number in a help dialog... perhaps wx has a utility method to read the version number from the running EXE?