 |
|
 |
How would you implement Russian alphabet handling in your RichEdit??
I would like to pass Russian characters or string from one RichEdit to another RichEdit (or control).
The point is that my Borland application or the text controls such as Memos and RichEdits do not pass or accept Russian alphabet or strings, instead it passes question marks. For instance, if I pass something like this ефкшудлф it would show this ???????? in the other control.
I've tried to read Borland's help but I haven't got answers.
I´ve also tried with this:
1. #define _UNICODE (but I´m not even sure if this is correct)
2. I´ve set RUSSIAN_CHARACTERS in the control's Font property
I hope there's sombody out there who can help me.
thanks in advance
CKeeto
C++ beginner
|
|
|
|
 |
|
 |
After resizing the window the gripper disappears and the status bar style seems to change. Many thanks for the code.
|
|
|
|
 |
|
 |
Does anyone knows, how to insert text at a specific location in the control? Thanks
Work hard and a bit of luck is the key to success. You don`t need to be genius, to be rich.
|
|
|
|
 |
|
 |
Can you give me more details?What do you want exactly to do?Do you mean that you want to insert for example a text at line 2?
|
|
|
|
 |
|
 |
Yes. For example, by choosing a menu, it will prompt you for line(s) of text. When you OK, then those lines will automatically inserted into the richeditcontrol or richeditView
Work hard and a bit of luck is the key to success. You don`t need to be genius, to be rich.
|
|
|
|
 |
|
 |
First of all you have to put the caret there and then to insert that line or waht you have to do.But how to put the caret there? Because there is only SetCaretPos(CPoint pt) and CPoint GetCaretPos().
|
|
|
|
 |
|
 |
I got it. First we get the string of the richEditControl, using GetText(), then manipulate the string and set the text to the RichEditControl again using SetText(). Thanks
Work hard and a bit of luck is the key to success. You don`t need to be genius, to be rich.
|
|
|
|
 |
|
 |
Here is a code snippet from NotepadRe from codeproject: http://www.codeproject.com/cpp/notepadre.Maybe helps you to insert a line in richedit control.Please tell me if this is useful or not.
The column must be 0 if you want to put the caret in front of the first character from the 4th line, let's say.
void CNotepadreView::OnEditGoto()
{
CGotoDlg Dlg;
if (Dlg.DoModal () == IDOK)
{
int iLine = Dlg.m_uiLine - 1;
int iColumn = Dlg.m_uiColumn - 1;
int iLineIndex = GetEditCtrl().LineIndex (iLine) + iColumn;
GetEditCtrl().SetSel(iLineIndex, iLineIndex);
}
}
|
|
|
|
 |
|
 |
Ok, I`ll try it at home. I`ll let you know the result.
What I tried :
1. Get the text of RichEdit Control as I said earlier.
2. Split it after the "\n", and stored it in a CStringArray.
3. Then you can manipulate the CStringArray ( add some CString ) into the CStringArray
4. Put together the CStringArray into one CString and set it to the Rich Edit Control again.
Thanks
Work hard and a bit of luck is the key to success. You don`t need to be genius, to be rich.
|
|
|
|
 |
|
 |
Could you add the code, so that it can add a simple text like "hello" in the fifth line for example?
Work hard and a bit of luck is the key to success. You don`t need to be genius, to be rich.
|
|
|
|
 |
|
 |
how to hide and show a Edit box with a id is IDC_EDIT1 when click a button once then will hide and click another once will hide.
|
|
|
|
 |
|
 |
I am not sure if i understood your question: where do you want to click in order to hide an edit control?Anyway, the ideea is the following:
CEdit myEdit;
myEdit.Show(SW_HIDE); // when you want to hide it
myEdit.Show(SW_SHOW); // when you want to show it
I hope it is useful and if it is not, please give more details.
|
|
|
|
 |
|
 |
hai ,
This show method does not even work in my system could u suggest any other method by which i can hide the controls and show them when needed.
Thanks & regards,
sunil.s
|
|
|
|
 |
|
 |
Is there some documentation on what RTF codes that a Richedit control supports and what it does not? Also, is there a way to have the control ignore the codes it does not support, but preserve them? For instance, if you copy/cut some formatted text from Word, and paste it into the Richedit ctontrol - formatting is mostly preserved. However, if the copied text includes a bookmark or footnote, that information is lost when text is pasted on to the Richedit control. I need to find a way to preserve this information - even if the control cannot display such item.
I would appreciate any pointers.
|
|
|
|
 |
|
 |
I have looked with the CLipboard Viewer and the header and footer of a *.doc file is not in the clipboard.
|
|
|
|
 |
|
 |
In RichEditCtrl I want to get any letter other than that I pressed from keyboard.
|
|
|
|
 |
|
 |
I have derived my view class from CFormView, and there is a rich edit ctrl in the form. I could not map the WM_CHAR Message in my project. How would I have it.
|
|
|
|
 |
|
 |
By default, a CRichEditCtrl doesn't send Notification messages to its parent. You need to use the SetEventMask member function to specify which notification messages to be send by the CRichEditCtrl.
For example in the constructor of the class in which you have the CRichEditCtrl:
m_yourRichEdit.SetEventMask(ENM_MOUSEEVENTS|ENM_KEYEVENTS);
Hope this helps
MS
|
|
|
|
 |
|
 |
Yes this worked. Thanks for this.
|
|
|
|
 |
|
 |
I get the following when I quit the debug EXE:
First-chance exception in MyRtf.exe (KERNEL32.DLL): 0xC0000005: Access Violation.
Detected memory leaks!
Dumping objects ->
oleinit.cpp(86) : {58} client block at 0x00301AE0, subtype 0, 68 bytes long.
a CCmdTarget object at $00301AE0, 68 bytes long
Object dump complete.
The thread 0x500 has exited with code 3 (0x3).
The program 'H:\My Documents\myrtf\Debug\MyRtf.exe' has exited with code 3 (0x3).
|
|
|
|
 |
|
 |
I don't know what to say.Now i don't have somuch time to check, but i will check.
|
|
|
|
 |
|
 |
I need an RTF-editor in some of my projects. I found this, which seems to be an excellent starting point for my requirements. So I replaced the RichText control with the newest version, as I run XP. The MFC-documentation tells us how:
"To update rich edit controls in existing Visual C++ applications to version 2.0, open the .RC file as text, change the class name of each rich edit control from "RICHEDIT" to "RichEdit20a". Then replace the call to AfxInitRichEdit with AfxInitRichEdit2".
I did just that and then compiled it with VS.NET 2003.
When terminating the program, I got an error that I assume it is a result of the same problem you mention. It was not a memory leak, though, it was an "Access violation" error. The problem turns out to be a private member (m_pTBButtons in MyToolBarCtrl.h) which is uninitialized. I removed the declaration of the member and the two references to it in MyToolBarCtrl.cpp (in the destructor). That cured the error.
|
|
|
|
 |
|
 |
Filomela, this is great.. have you or anyone on this group thought of doing a dotnet wrapper for it? seems to have been left out of the framework!!
Please email me if anyone has done a wrapper, or repost as a new article that would be *VERY* useful!!
Thanks.
________________________________________
Gosh, it would be awful pleas'n, to reason out the reason, for things I can't explain.
Then perhaps I'd deserve ya, and be even worthy of ya..
if I only had a brain!
|
|
|
|
 |
|
 |
Yes, I have thinked about this but I don't know .NET.If I knew I would do it.
|
|
|
|
 |
|
 |
Well, you are 90% of the way there-- you have a great reason to learn .net!
seriously, it's way simple, you can even use managed c++ and treat the .net framework purely as a library, which it is. But you should really just get visual studio/ c# and start coding. c#/ dotnet is the best product that ms has put out in 10 years, and once you start you will never look back.
There are also lots of examples on codeproject, from tutorial on through how to wrap all the things framework left out, check them out, stay in touch!!
________________________________________
Gosh, it would be awful pleas'n, to reason out the reason, for things I can't explain.
Then perhaps I'd deserve ya, and be even worthy of ya..
if I only had a brain!
|
|
|
|
 |