Search found 380 matches
- Mon Jan 20, 2020 12:09 am
- Forum: C++ Development
- Topic: WarpPointer question
- Replies: 8
- Views: 1043
Re: WarpPointer question
I agree that it is not good practice to move the mouse pointer programmatically... However, I want the behavior of using the wheel to zoom (in/out) with the position of the cursor determining which part of the image/diagram should be shown in the center of the window. So if I want the see the upper...
- Wed Jan 15, 2020 10:57 pm
- Forum: C++ Development
- Topic: How to use wxDCOverlay?
- Replies: 7
- Views: 744
Re: How to use wxDCOverlay?
If you want to draw with transparency with wxGraphicsContext while caching the result in a bitmap, I would try adding a function like this: void CAnalysisPanel::BuildPlot(int width, int height) { wxImage img(width,height); // Create an alpha channel and set all pixels transparent. img.InitAlpha(); m...
- Wed Jan 15, 2020 11:06 am
- Forum: C++ Development
- Topic: How to use wxDCOverlay?
- Replies: 7
- Views: 744
Re: How to use wxDCOverlay?
New Pagodi: yes, this seems the classical approach and I probably stay with it, it also allows me to cache separate bitmap for more plots and then just compose them when needed. Although the usage seems much more complicated, e.g. how to plot the lines into the transparent wxMemoryDC so I can compo...
- Tue Jan 14, 2020 2:21 pm
- Forum: C++ Development
- Topic: How to use wxDCOverlay?
- Replies: 7
- Views: 744
Re: How to use wxDCOverlay?
I think a better approach would be to cache the plots into a bitmap. The paint handler would first draw the bitmap and then draw any extra lines over the bitmap. To generate the cached bitmap of the plot, you can use wxMemoryDC.
- Sun Jan 05, 2020 6:47 pm
- Forum: C++ Development
- Topic: Larger then 69 wxTextCtrl font size?
- Replies: 3
- Views: 439
Re: Larger then 69 wxTextCtrl font size?
I believe the problem is due to this issue. According to the ticket, the workaround is to call SetPointSize after creating the font.
- Sat Jan 04, 2020 4:45 pm
- Forum: Compiler / Linking / IDE Related
- Topic: Using wxWidgets with Visual Studio Build Tools (2019)
- Replies: 2
- Views: 498
Re: Using wxWidgets with Visual Studio Build Tools (2019)
My gut feeling is that in order to debug a program that has used the Visual Studio Build Tools compiler (cl.exe), one requires the Visual Studio Debugger, and that no matter how hard I try, gdb won't understand the debugging symbols,etc produced. However as the VS debugger is only available in Visu...
- Sat Dec 28, 2019 5:45 pm
- Forum: C++ Development
- Topic: wxStyledTextCtrl search vs Scintilla
- Replies: 2
- Views: 353
Re: wxStyledTextCtrl search vs Scintilla
If you call
subsequent search operations will be case sensitive.
Code: Select all
SetSearchFlags(wxSTC_FIND_MATCHCASE)
- Wed Nov 27, 2019 12:47 am
- Forum: General Development
- Topic: draw rectangle over video
- Replies: 4
- Views: 886
Re: draw rectangle over video
I agree with doublemax. I think libvlc is your best (and maybe only) possibility.
- Tue Nov 26, 2019 8:05 am
- Forum: C++ Development
- Topic: How to convert a codepoint to utf8
- Replies: 3
- Views: 444
Re: How to convert a codepoint to utf8
You can convert a unicode code point to a wxUniChar . Usually unicode code points are listed in hexadecimal. To take your example, decimal 61 is 0x41 in hexadecimal, and you can look up that the unicode code point is U+0041 listed as "LATIN CAPITAL LETTER A" . You can create this a wxUniChar for thi...
- Sat Nov 23, 2019 10:47 pm
- Forum: C++ Development
- Topic: Bug with wxStyledTextCtrl::GetCurrentPois in wxEVT_STC_UPDATEUI
- Replies: 3
- Views: 1189
Re: Bug with wxStyledTextCtrl::GetCurrentPois in wxEVT_STC_UPDATEUI
This sounds like this issue. It was recently fixed. If you can, try using the latest version from git. If that's not an option, try using CallAfter as discussed in the first comment on that ticket.
If your issue still happens with the latest version from git, open a new ticket.
If your issue still happens with the latest version from git, open a new ticket.
- Sun Nov 17, 2019 5:02 am
- Forum: C++ Development
- Topic: wxStyledTextCtrl for HTML + CSS + JS
- Replies: 3
- Views: 509
Re: wxStyledTextCtrl for HTML + CSS + JS
Sorry, no lexer currently supports this. There was a recent discussion on the Scintilla list about this very question.
- Thu Nov 14, 2019 11:55 pm
- Forum: Platform Related Issues
- Topic: mediactrl.Load always gives False
- Replies: 16
- Views: 2010
Re: mediactrl.Load always gives False
I haven't tried it with soundfonts, but usually you can pass the same command line options to libvlc that you can pass to the VLC exe. (In the call to libvlc_new). https://wiki.videolan.org/VLC_command-line_help --soundfont=<string> SoundFont file For some reason, that doesn't seem to work. What I ...
- Thu Nov 14, 2019 9:36 pm
- Forum: Platform Related Issues
- Topic: mediactrl.Load always gives False
- Replies: 16
- Views: 2010
Re: mediactrl.Load always gives False
It looks like vlc will play midi files and that would probably be a better cross platform approach anyway.
However you need to specify a soundfont file. With the vlc binary this just requires setting an option. I cant quite figure out how to do this through the libvlc interface.
However you need to specify a soundfont file. With the vlc binary this just requires setting an option. I cant quite figure out how to do this through the libvlc interface.
- Wed Sep 04, 2019 10:56 pm
- Forum: C++ Development
- Topic: Can wxDC::DrawBitmap(...true) even draw bitmaps with alpha channels?
- Replies: 10
- Views: 702
Re: Can wxDC::DrawBitmap(...true) even draw bitmaps with alpha channels?
[/code]The RGB values must be pre-multiplied with alpha. writeIt.Red() = readIt->r * readIt->a / 256; I don't know if this matters, but the way building a wxBitmap from RGBA data is done in the wxSTC source is p.Red() = wxPy_premultiply(red, alpha); p.Green() = wxPy_premultiply(green, alpha); p.Blu...
- Thu Aug 22, 2019 10:07 pm
- Forum: Component Writing
- Topic: Blender DAG node graph
- Replies: 12
- Views: 3422
Re: Blender DAG node graph
No, I'm talking about native boxes where the user can input data themselves, not wxStaticText. Just like in the Blender picture above. One way to do this using the renderer/editor division of labor. wxWidgets uses this for wxGrid, wxDataViewCtrl, and wxPropgrid. The idea is to bring up the editor (...