Search found 14 matches

by PeterO
Thu Sep 12, 2019 6:25 pm
Forum: C++ Development
Topic: wxRichTextCtrl bug: style applied to whole line on enter
Replies: 12
Views: 2497

Re: wxRichTextCtrl bug: style applied to whole line on enter

It does - look at the wxTextCtrl with TE_RICH2 style. However, there are some other OSes which does not have support for different styling, paragraph, etc. Yes, wxTextCtrl uses the native control. But wxRTC doesn't, it draws text itself using wxDC::DrawText. But just like wxDataViewCtrl has a nativ...
by PeterO
Wed Sep 11, 2019 8:52 am
Forum: C++ Development
Topic: wxRichTextCtrl bug: style applied to whole line on enter
Replies: 12
Views: 2497

Re: wxRichTextCtrl bug: style applied to whole line on enter

Question: If wxWidgets purpose is to use the platform's native API as much as possible, why doesn't wxRTC use/wrap the richedit control shipped with Windows with all it's functionality? AFAICS it has al the styling and paragraph formatting. https://docs.microsoft.com/en-us/windows/win32/controls/abo...
by PeterO
Tue Sep 10, 2019 9:09 am
Forum: C++ Development
Topic: wxRichTextCtrl bug: style applied to whole line on enter
Replies: 12
Views: 2497

Re: wxRichTextCtrl bug: style applied to whole line on enter

Yes I noticed the other open tickets regarding wxRichTextCtrl. I'm already trying to grasp what's going on but have a hard time understanding some portions of the code. The styling of the paragraph where the break happens is done here: https://github.com/wxWidgets/wxWidgets/blob/master/src/richtext/...
by PeterO
Tue Sep 10, 2019 8:09 am
Forum: C++ Development
Topic: wxRichTextCtrl bug: style applied to whole line on enter
Replies: 12
Views: 2497

Re: wxRichTextCtrl bug: style applied to whole line on enter

evstevemd wrote: Tue Sep 10, 2019 7:09 am Does it happen with richtexteditor sample?
Yes. See the ticket I made for it and it's attachment: https://trac.wxwidgets.org/ticket/18494
by PeterO
Tue Sep 10, 2019 6:53 am
Forum: C++ Development
Topic: wxRichTextCtrl bug: style applied to whole line on enter
Replies: 12
Views: 2497

Re: wxRichTextCtrl bug: style applied to whole line on enter

Windows 10, 1903
wxWidgets master branch latest-dev (as well as v3.1.2)

Noticed if I first center the text and do the same it's handled ok:
style ok.png
style ok.png (713 Bytes) Viewed 2469 times
by PeterO
Mon Sep 09, 2019 9:29 pm
Forum: C++ Development
Topic: wxRichTextCtrl bug: style applied to whole line on enter
Replies: 12
Views: 2497

wxRichTextCtrl bug: style applied to whole line on enter

I've got this simple rich text: r.WriteText("aaa"); r.BeginTextColour(*wxRED); r.WriteText("bbb"); r.EndTextColour(); r.WriteText("ccc"); It shows as expected. style bug - before.png But when I Enter in the middle of the coloured section the whole first line is red styl...
by PeterO
Tue Aug 20, 2019 10:52 am
Forum: C++ Development
Topic: Mixed read-only/editable text
Replies: 2
Views: 646

Re: Mixed read-only/editable text

Thanks, that's what I was searching for.
by PeterO
Tue Aug 20, 2019 7:44 am
Forum: C++ Development
Topic: Mixed read-only/editable text
Replies: 2
Views: 646

Mixed read-only/editable text

Hello everyone

I would like to have a textcontrol with mixed read-only/editable text parts. In HTML you can achieve this by using the contenteditable attribute in a span. Is this possible with one of the native controls as well?

Thx in advance,
Peter
by PeterO
Sun Aug 18, 2019 8:16 pm
Forum: C++ Development
Topic: wxDataViewCtrl Tab Navigation
Replies: 0
Views: 7442

wxDataViewCtrl Tab Navigation

Regarding the wxDataViewCtrl: Using the tab-key on a row which has no children (but with containercolumns) will advance the focus to the next column/cell. But how can I advance the focus to the next column/cell if a row has children (and with containercolumns)? Because in that case it will expand th...
by PeterO
Mon Mar 11, 2019 2:52 pm
Forum: C++ Development
Topic: Async drag drop
Replies: 4
Views: 808

Re: Async drag drop

Because this might be a lengthy operation, or we might need user input, or whatever, reason doesn't matter. We don't want to block the UI and at the end of the operation I need a callback so the source will be removed (or another cleanup processing). MSW has an interface for it so this is a reasonab...
by PeterO
Mon Mar 11, 2019 10:26 am
Forum: C++ Development
Topic: Async drag drop
Replies: 4
Views: 808

Async drag drop

Hello Is it possible to do async drag drop? In our specific case, the processing of data on drop will be done on a worker thread to prevent blocking the UI thread. But afterwards we need to know if the process has succeeded to perform deleting the source. In MSW there's a IDataObjectAsyncCapability ...
by PeterO
Mon Jun 30, 2014 6:41 am
Forum: C++ Development
Topic: wxString::FromCDouble is locale dependent
Replies: 3
Views: 1672

Re: wxString::FromCDouble is locale dependent

Ticket #16343 has been fixed.
by PeterO
Mon Jun 23, 2014 1:10 pm
Forum: C++ Development
Topic: wxString::FromCDouble is locale dependent
Replies: 3
Views: 1672

Re: wxString::FromCDouble is locale dependent

Ok, I've made a new ticket: #16343
by PeterO
Mon Jun 23, 2014 11:24 am
Forum: C++ Development
Topic: wxString::FromCDouble is locale dependent
Replies: 3
Views: 1672

wxString::FromCDouble is locale dependent

Hello there. On initializing my application I want to set the global locale to the system locale by calling wxLocale.Init(); But wxLocale.Init() only sets the C global locale to the system locale. To set the C++ global locale as well I call: std::locale::global(std::locale(setlocale(LC_ALL, NULL)));...