Suggesting a feature

This forum is reserved for everything you want to talk about. It could be about programming, opinions, open source programs, development in general, or just cool stuff to share!
Post Reply
bigpilot
I live to help wx-kind
I live to help wx-kind
Posts: 183
Joined: Tue Sep 19, 2006 8:33 am

Suggesting a feature

Post by bigpilot »

I would like to ask the wxWidgets developers to develop a single-line rich text edit control. Any idea what the best to go about this?
Soon to be world famous ;)
PB
Part Of The Furniture
Part Of The Furniture
Posts: 4183
Joined: Sun Jan 03, 2010 5:45 pm

Re: Suggesting a feature

Post by PB »

You can create a ticket on wxTrac or ask in the wx-users mailing group but TBH, IMO the chances for this being implemented are very low.

AFAIK, the original author of wxRichTextCtrl is not very active and since its code is quite complex, other people are very keen on modifying it.

I have no experience with wxRichTextCtrl so I assume you tried to make it work as a single line control but failed?

Can't you use just wxTextCtrl with wxTE_RICH2 and wxTextAttr? But I am not sure this would work in a single line mode either.
bigpilot
I live to help wx-kind
I live to help wx-kind
Posts: 183
Joined: Tue Sep 19, 2006 8:33 am

Re: Suggesting a feature

Post by bigpilot »

I can't use wxTextCtrl with the wxTE_RICH2 flag since it isn't supported on the other platforms. I need the solution to work on all platforms.

I'll try entering a wxTrac issue. Otherwise I'll have no choice but to modify RichTextCtrl myself.
Soon to be world famous ;)
User avatar
doublemax
Moderator
Moderator
Posts: 19103
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: Suggesting a feature

Post by doublemax »

What exactly do you want to achieve? If you just want a single line wxRichTextCtrl you could try to catch the wxEVT_CHAR event and consume all "return" presses.
Use the source, Luke!
PB
Part Of The Furniture
Part Of The Furniture
Posts: 4183
Joined: Sun Jan 03, 2010 5:45 pm

Re: Suggesting a feature

Post by PB »

bigpilot wrote: Tue Jul 07, 2020 2:12 pm I can't use wxTextCtrl with the wxTE_RICH2 flag since it isn't supported on the other platforms. I need the solution to work on all platforms.
While wxTE_RICH(2) is for MSW only and required there to support formatting, are you sure wxTextCtrl on the other platforms does not support formatting (although it is not same as wxRichTextCtrl)? I think a single-line text control may need just font and color formatting, not paragraph formatting, tables, embedded pictures etc.

I am MSW only but I think it is supposed to work everywhere. You can easily test it with the bundled Text sample. I tested in a VM with Linux Mint:
mint-textctrl.png
mint-textctrl.png (66.98 KiB) Viewed 16885 times
ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 7449
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: Suggesting a feature

Post by ONEEYEMAN »

Hi,
Let's start from the beginning - what feature of wxRTC you are looking for?

And are you sure you want the single line control? What is wrong with multiline?

Thank you.
bigpilot
I live to help wx-kind
I live to help wx-kind
Posts: 183
Joined: Tue Sep 19, 2006 8:33 am

Re: Suggesting a feature

Post by bigpilot »

I'm trying to build something similar to the Outlook Express email address To and From fields.

I'm currently using a multi-line RichTextCtrl but I find it doesn't really look like a single line textcontrol, it looks more like a 1,5 line text control.
Soon to be world famous ;)
ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 7449
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: Suggesting a feature

Post by ONEEYEMAN »

Hi,
Are you using sizers?
Can you post some code?

Thank you.
User avatar
doublemax
Moderator
Moderator
Posts: 19103
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: Suggesting a feature

Post by doublemax »

bigpilot wrote: Sat Apr 24, 2021 8:25 pm I'm trying to build something similar to the Outlook Express email address To and From fields.
Why would you need a "rich" text control for that?
Use the source, Luke!
bigpilot
I live to help wx-kind
I live to help wx-kind
Posts: 183
Joined: Tue Sep 19, 2006 8:33 am

Re: Suggesting a feature

Post by bigpilot »

I need to underline the recipients that have been found in the address book. Outlook Express works the same way.
Soon to be world famous ;)
ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 7449
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: Suggesting a feature

Post by ONEEYEMAN »

Hi,
And SetFont() doesn't work for you in a regular text control? Or even the one with wxTE_RICH2?

Thank you.
Post Reply