richtextbox

RichTextBox Text Positioning

Hello, I'm building a simple application, but I need to know how to use a RichTextBox and position the text on it, like: center, right and left. But how I can do this? ...

Maximize Components Too

I have a Windows Forms application that on it I have a RichTextBox, like this: At this size it's all ok, but if the user maximaze or resize the window, the RichTextBox stays at the same size, but how to resize the RichTextBox too? ...

Clearing all RichTextBoxes from a form (VB.NET)

I have a form with 25 RichTextBoxes. I need to clear them all when a user presses a button. I think it's something to do with: Me.Controls.Clear but I'm not sure. Thanks for any help. :) ...

Silverlight Rich text box control

Our team decided that we need our own custom Rich text box control for Silverlight app we are developing. We looked at existing controls mentioned at http://stackoverflow.com/questions/1372038/a-good-rich-text-control-for-silverlight but decided to build our own,due to varios reasons. We are planning to build it in stages, with elementar...

RichTextBox specific colors per few characters / lines C#

I have richTextBox1, and here is the contents: line one from my textbox is this, and i want this to be normal, arial, 8 point non-bold font line two, i want everything after the | to be bolded... | this is bold line three: everything in brackets i (want) to be the color (Red) line 4 is "this line is going to be /slanted/ or with ital...

making a simple search function, making the cursor jump to (or highlight) the word that is searched for.

Dear community. I have now used way too long time, trying to figure out a problem, which I didn't think would be that hard. Here is the deal: I am writing a small application using C# and WPF. I have a RichTextBox containing a FlowDocument. I have added a small textbox and a button below my richtextbox. The user then types in the w...

WPF - Style for the scrollbars and background on a RichTextBox

What's required to create a style for a RichTextBox that includes visuals for the scrollbars and a background color for the space behind the text? ...

Winforms RichTextBox: How can I scroll the caret to the middle of the RichTextBox?

I want to scroll a RichTextBox so that the caret is approximately in the middle of the RichTextBox. Something like RichTextBox.ScrollToCaret(), except I don't want to put the caret at the very top. I saw Winforms: Screen Location of Caret Position, and of course also saw the Win32 function SetCaretPos(). But I'm not sure how to tra...

Winforms RichTextBox: How can I determine how many lines of text are visible?

I have a Winforms app containing a RichTextBox. How can I determine how many lines of text are displayed, currently visible? Reason: I want to scroll the caret to the middle of the RichTextBox. I can use RichTextBox.ScrollToCaret(), but that puts the caret at the top of the RichTextBox. I figure, If I know how many lines are dis...

Controlling horizontal scroll in RichTextBox

I have a RichTextBox that I'm spewing log information to, but the RichTextBox seems to want to horizontally scroll whenever text is appended that is too long to fit. After searching extensively, and repeatedly failing with ScrollToCaret(), it would seem that this function controls the vertical scroll position, but not the horizontal. I...

displaying html text within a wicket element

i'm trying to display html i.e. rich text within a wicket element dynamically. An example is like displaying a rich text email within a div tag. how can i get this done with wicket. the wicket Label component doesn't seem to support this. is there a component that does ...

How to get asian (Japanese) text from RichTextBox into a CString

Help, stuck wiht getting unicode text from RichTextBox in managed C++. I am trying to read rtb->Text into a CString object expecting to see something like: "\u33655?\u26538?\u23454?\u24377?\u30340?" The rtb->Text shows a proper Japanese characters but I cannot write them into a DB. So I need a wchar representation of the Japanese charac...

RichTextBox use to retrieve Text property in C++

I am using a hidden RichTextBox to retrieve Text property from a RichEditCtrl. rtb->Text; returns the text portion of either English of national languages – just great! But I need this text in \u12232? \u32232? instead of national characters and symbols. to work with my db and RichEditCtrl. Any idea how to get from “пассажирским поезд...

Rich text editor with blockquote function

Hi there, It's me again, the one who doesn't want to use a plugin, but write my own or use some lines from other plugins ;-). I want to write a simple RTE with the functions bold, italic, list, emoticons and blockquote. I found this simple lightweight plugin http://batiste.dosimple.ch/blog/posts/2007-09-11-1/rich-text-editor-jquery.htm...

Inserting at top of richtextbox

Hey guys, Whats wrong with this code? Trying to get my text to insert at the beginning of the textbox rather than at the bottom. private void execute_Click(object sender, EventArgs e){ startFinshBox.Text = "Start Time: " + printTime()+""; startFinshBox.Text.Insert(0,printTime()+": Retrieving Results...\n"); } But it will not ins...

C# WPF convert BitmapImage pasted in richtextbox to binary

Hi everyone, I've got a richtextbox, that I plan on saving to a database, which can be loaded back into the same richtextbox. I've got it working so that I can save the flowdocument as DataFormats.XamlPackage, which saves the images, but the issue is that the text isn't searchable. With DataFormats.Xaml, I've got the text of course, b...

C#, RichTextBox: how to implement scrolling line by line?

Hi! I have a RichTextBox in my C#-application. Both horizontal and vertical scrolling are enabled. Current behavior: When I reach the last line of visible text area, horisontal scrolling comes to place. But scrolling is being made by pixels, not by line. So I can't see the text I'm typing becase the line itself is partly (or completely...

C#: Synchronize Scroll Position of two RichTextBoxes?

In my application's form, I have two RichTextBox objects. They will both always have the same number of lines of text. I would like to "synchronize" the vertical scrolling between these two, so that when the user changes the vertical scroll position on one, the other scrolls the same amount. How might I go about doing this? ...

Saving (Rich)TextBox's to memory and switching them off with a richtextbox in my form in C#

My goal is to have one main richtextbox in the form, and then several different richtextbox's in the backround, the backround textbox's get added, removed, and edited behind the scences all the time... and i need a way to swap my richtextbox in the form with the richtextbox's in the backround. what i origannally had was a Dictionary Di...

RichTextBox in WPF not resizing contents correctly

I need to display text with colors and formatting in a List. I'm using a ListBox with a RichTextControl to display the data. I also need the contents to size to the window, but the text does not need to wrap. When I make this simple example the text appears vertical and doesn't change as I size the window. If I set the Width of the Rich...