Search found 216 matches

by Rudra
Thu Sep 05, 2019 2:29 pm
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxExecute with wxEXEC_ASYNC in wxThreadEventHandler triggers wxApp::OnExit()
Replies: 1
Views: 59

[wxMSW][wx3.0.3] wxExecute with wxEXEC_ASYNC in wxThreadEventHandler triggers wxApp::OnExit()

Hi I my wx application, I have a join able thread. From wxThread::Entry() function, I am posting an event as follows, wxThreadEvent* evt = new wxThreadEvent(); evt->SetId(kMerge); wxQueueEvent(wxTheApp, evt); When wxThreadEventHandler is triggered, I am launching an exe (ffmpeg app) using wxExecute ...
by Rudra
Tue Aug 20, 2019 7:04 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxRichTextCtrl: Getting buffer as HTML does not add width and height of embedded image
Replies: 3
Views: 74

Re: [wxMSW][wx3.0.3] wxRichTextCtrl: Getting buffer as HTML does not add width and height of embedded image

Thanks for the reply I use the output html string to insert in a web page. Even if I don't set the wxRICHTEXT_HANDLER_SAVE_IMAGES_TO_BASE64 flag, I get same html data. Hence always get image in original size rather than modified size on web page. // Get as html data wxString text; wxStringOutputStre...
by Rudra
Mon Aug 19, 2019 2:46 pm
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxRichTextCtrl: Getting buffer as HTML does not add width and height of embedded image
Replies: 3
Views: 74

[wxMSW][wx3.0.3] wxRichTextCtrl: Getting buffer as HTML does not add width and height of embedded image

Hi I am trying to get the wxRichTextCtrl's buffer as HTML string using wxRichTextHTMLHandler. I set handler's flag to wxRICHTEXT_HANDLER_SAVE_IMAGES_TO_BASE64. If I resize the embedded image using Picture Properties Dialog that comes on right clicking the image, It does not add any width or height p...
by Rudra
Tue Aug 13, 2019 7:21 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxRichTextCtrl: Loading HTML string.
Replies: 2
Views: 88

Re: [wxMSW][wx3.0.3] wxRichTextCtrl: Loading HTML string.

Thanks for the reply. I was stuck. I tried XML handler and it works for me. I can save the rich text as XML and load it later. Code is as follows, // Save wxStringOutputStream strStream(m_rtcStr); wxRichTextXMLHandler xmlHander; xmlHander.SetFlags(wxRICHTEXT_HANDLER_SAVE_IMAGES_TO_BASE64); // save e...
by Rudra
Mon Aug 12, 2019 11:40 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxRichTextCtrl: Loading HTML string.
Replies: 2
Views: 88

[wxMSW][wx3.0.3] wxRichTextCtrl: Loading HTML string.

Hi, I looked into forum and found following links that says loading HTML content is not supported in wxRichTextCtrl. https://forums.wxwidgets.org/viewtopic.php?t=38274 https://forums.wxwidgets.org/viewtopic.php?t=45019 I have a function in which I can save the RTC's content as HTML and edit later if...
by Rudra
Mon Aug 12, 2019 7:16 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] Get menu-item label on click of a dynamically added menu in toolbar
Replies: 2
Views: 82

[wxMSW][wx3.0.3] Get menu-item label on click of a dynamically added menu in toolbar

Hi, In my wx application, I have wxITEM_DROPDOWN tool in which I am adding menu-items dynamically as follows, m_tooBar = new wxToolBar(m_titlePanel, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTB_NODIVIDER|wxTB_HORZ_TEXT); m_tooBar->AddTool(wxID_LOAD, wxT("Load"), wxMEMORY_PNG(ICON_LOAD), wxMEMORY...
by Rudra
Mon Aug 05, 2019 9:06 am
Forum: C++ Development
Topic: [wxMSW[3.0.3] Convert plain text to html text
Replies: 4
Views: 110

Re: [wxMSW[3.0.3] Convert plain text to html text

Thanks for the reply. What kind of issues? Initially, I was not handling '<', so it was not getting displayed in list if input string has it. e.g if input string is "a<c" then I was seeing only "a" in list. I don't see any problem with '>' and '&'. It gets displayed okay. I have to replace the '<'' ...
by Rudra
Fri Aug 02, 2019 7:46 am
Forum: C++ Development
Topic: [wxMSW[3.0.3] Convert plain text to html text
Replies: 4
Views: 110

[wxMSW[3.0.3] Convert plain text to html text

Hi In my wx application, I am getting plain text from wxTextCtrl and loading to wxSimpleHtmlListBox. The text can contain new line and any html entity like & >, < etc. I am handling it manually (i.e Replacing _T('<') with _T("<"), _T('\n') with _T("<br/>") and so on) when I find issue in displaying ...
by Rudra
Fri Jul 05, 2019 11:37 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxSimpleHtmlListBox: Wrapping long text without spaces
Replies: 3
Views: 93

Re: [wxMSW][wx3.0.3] wxSimpleHtmlListBox: Wrapping long text without spaces

Thanks for the reply. yes, the <wbr>, ­ or ​ (Zero-width space) are not supported by wxHTML. Let me explain little bit more what I am doing. Each row of my wxSimpleHtmlListBox is a table. I am calculating the possible width using wxDC::GetTextExtent(wxString) and setting the width of HTML ...
by Rudra
Thu Jul 04, 2019 10:59 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxSimpleHtmlListBox: Wrapping long text without spaces
Replies: 3
Views: 93

[wxMSW][wx3.0.3] wxSimpleHtmlListBox: Wrapping long text without spaces

Hi, In my wx application, I show a wxSimpleHtmlListBox. I noticed that a long text, not having spaces, doesn't get wrap. The list shows horizontal scrollbar. If text contains spaces then it does wrap. I don't want to show horizontal scroll bar. I want to wrap around the width of wxSimpleHtmlListBox....
by Rudra
Thu Jul 04, 2019 7:17 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] Closed dialog being shown on clicking on taskbar's thumbnail preview of wxFrame
Replies: 2
Views: 106

Re: [wxMSW][wx3.0.3] Closed dialog being shown on clicking on taskbar's thumbnail preview of wxFrame

Thanks for the reply. I see that problem was passing NULL as parent. Passing "this" (wxFrame) fixes the problem. I also tried to explore the dialogs sample and modified the parent of dialog opened from menu-item : "Generic Dialogs > Model less dialog" to NULL and close instead of hide on unchecking ...
by Rudra
Mon Jul 01, 2019 7:46 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] Closed dialog being shown on clicking on taskbar's thumbnail preview of wxFrame
Replies: 2
Views: 106

[wxMSW][wx3.0.3] Closed dialog being shown on clicking on taskbar's thumbnail preview of wxFrame

Hi In my wx application On Win-OS 10, I show a model-less dialog(wxDialog) from wxFrame. I noticed that even I closed the opened dialog, it appears on clicking thumbnail preview of wxFame on taskbar for a second. When wxFrame comes on top, because of clicking on thumbnail preview, it shows for a sec...
by Rudra
Wed Jun 12, 2019 9:16 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxRichTextCtrl, wxColorPickerCtrl and wxUpdateUIEvent
Replies: 7
Views: 185

Re: [wxMSW][wx3.0.3] wxRichTextCtrl, wxColorPickerCtrl and wxUpdateUIEvent

ONEEYEMAN wrote:
Tue Jun 11, 2019 3:12 pm
Did you look at wxSTC?
No, I didn't look at it. I looked into richtext sample first and wanted similar function like it has.

I did take a look after you mentioned and wxSTC seems more rich. I should have known this.

Thanks for mentioning it.

Thank you
R.
by Rudra
Wed Jun 12, 2019 9:09 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] wxRichTextCtrl, wxColorPickerCtrl and wxUpdateUIEvent
Replies: 7
Views: 185

Re: [wxMSW][wx3.0.3] wxRichTextCtrl, wxColorPickerCtrl and wxUpdateUIEvent

To use the styles you can either call SetDefaultStyle() before inserting the text or call SetStyle() later to change the style of the text already in the control (the first solution is much more efficient). Adding space and setting style then deleting the space works better than SetDefaultStyle(), ...