|
Home > Archive > Whish List > September 2005 > Editor object -- need a means of determining selected text
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Editor object -- need a means of determining selected text
|
|
| Ken Mayer [dBVIPS] 2005-09-09, 1:24 pm |
| I would like to suggest a way to hook into the editor's selected text.
We know that cut/copy can be used to take text that his selected and
place it in the clipboard.
What I would like to be able to do is determine the text that is
selected (highlighted by the user), and also have access to the
start/end position within the text in an editor control, and be able to
do something with it, such as add HTML formatting tags at the
beginning/end of the text ...
Ken
--
/(Opinions expressed are purely my own, not those of dataBased
Intelligence, Inc.)/
*Ken Mayer* [dBVIPS]
/Golden Stag Productions/
dBASE at goldenstag dot net
http://www.goldenstag.net/GSP
http://www.goldenstag.net/dbase
| |
| Kathy Kolosky 2005-09-12, 11:23 am |
| Hi Ken. Maybe I'm missing something. But, I used the fish.dbf
"Ken Mayer [dBVIPS]" < dbase@_nospam_golden
stag.net> wrote in message
news:yxjtiEWtFHA.304@news-server...
>I would like to suggest a way to hook into the editor's selected text. We
>know that cut/copy can be used to take text that his selected and place it
>in the clipboard.
>
> What I would like to be able to do is determine the text that is selected
> (highlighted by the user), and also have access to the start/end position
> within the text in an editor control, and be able to do something with it,
> such as add HTML formatting tags at the beginning/end of the text ...
>
> Ken
> --
> /(Opinions expressed are purely my own, not those of dataBased
> Intelligence, Inc.)/
>
> *Ken Mayer* [dBVIPS]
> /Golden Stag Productions/
> dBASE at goldenstag dot net
> http://www.goldenstag.net/GSP
> http://www.goldenstag.net/dbase
| |
| Kathy Kolosky 2005-09-12, 11:23 am |
| Oops.. jumped the gun sending the previous post.
If I'm understanding you correctly are you saying that you want to be able
to view the html code in the editor after it is highlighted by the user?
I did notice that you can add html code directly in the editor but, the only
way to view what html tags there are is to copy and paste to another source.
Thanks, Kathy
"Kathy Kolosky" <kkolosky@databi.com> wrote in message
news:3FabjF7tFHA.304@news-server...
> Hi Ken. Maybe I'm missing something. But, I used the fish.dbf
> "Ken Mayer [dBVIPS]" < dbase@_nospam_golden
stag.net> wrote in message
> news:yxjtiEWtFHA.304@news-server...
>
>
| |
| Ken Mayer [dBVIPS] 2005-09-12, 8:24 pm |
| Kathy Kolosky wrote:
> Oops.. jumped the gun sending the previous post.
>
> If I'm understanding you correctly are you saying that you want to be able
> to view the html code in the editor after it is highlighted by the user?
>
> I did notice that you can add html code directly in the editor but, the only
> way to view what html tags there are is to copy and paste to another source.
We're working in another newsgroup around some of these limitations, but
it's all very weird.
Let's say I have an editor control on a form. I then want the user to be
able to highlight some text, and using a pushbutton change that text to
boldface. Currently we're having to cut this code OUT of the text (using
the editor object cut() method to cut it to the clipboard) in the
editor, keyboard the bold tag, paste the text back (paste() method), and
keyboard the end tag. That's awfully clumsy. It also removes the
highlighting of the text, in case the user wants other formatting (they
then have to highlight it again).
It would be nice to be able to know the position by character in the
text at the beginning of the highlighted block, and at the end of the
highlighted block, to be able to insert the tags directly. This can also
be done but it's a real bear right now.
Ken
--
/(Opinions expressed are purely my own, not those of dataBased
Intelligence, Inc.)/
*Ken Mayer* [dBVIPS]
/Golden Stag Productions/
dBASE at goldenstag dot net
http://www.goldenstag.net/GSP
http://www.goldenstag.net/dbase
| |
| Kathy Kolosky 2005-09-12, 8:24 pm |
| Ah. OK. I've submitted this as QAID 5540
Thanks,
Kathy
QA
dBI
"Ken Mayer [dBVIPS]" < dbase@_nospam_golden
stag.net> wrote in message
news:5XuMtm8tFHA.1232@news-server...
> Kathy Kolosky wrote:
>
> We're working in another newsgroup around some of these limitations, but
> it's all very weird.
>
> Let's say I have an editor control on a form. I then want the user to be
> able to highlight some text, and using a pushbutton change that text to
> boldface. Currently we're having to cut this code OUT of the text (using
> the editor object cut() method to cut it to the clipboard) in the editor,
> keyboard the bold tag, paste the text back (paste() method), and keyboard
> the end tag. That's awfully clumsy. It also removes the highlighting of
> the text, in case the user wants other formatting (they then have to
> highlight it again).
>
> It would be nice to be able to know the position by character in the text
> at the beginning of the highlighted block, and at the end of the
> highlighted block, to be able to insert the tags directly. This can also
> be done but it's a real bear right now.
>
> Ken
>
> --
> /(Opinions expressed are purely my own, not those of dataBased
> Intelligence, Inc.)/
>
> *Ken Mayer* [dBVIPS]
> /Golden Stag Productions/
> dBASE at goldenstag dot net
> http://www.goldenstag.net/GSP
> http://www.goldenstag.net/dbase
| |
| Ken Mayer [dBVIPS] 2005-09-12, 8:24 pm |
| Kathy Kolosky wrote:
> Ah. OK. I've submitted this as QAID 5540
Thanks!
Ken
--
/(Opinions expressed are purely my own, not those of dataBased
Intelligence, Inc.)/
*Ken Mayer* [dBVIPS]
/Golden Stag Productions/
dBASE at goldenstag dot net
http://www.goldenstag.net/GSP
http://www.goldenstag.net/dbase
| |
| Ken Mayer [dBVIPS] 2005-09-12, 8:24 pm |
| Kathy Kolosky wrote:
> Ah. OK. I've submitted this as QAID 5540
You might want to add to this the ability to determine if any text is
selected (so you could enable/disable buttons, and so on ...).
Ken
--
/(Opinions expressed are purely my own, not those of dataBased
Intelligence, Inc.)/
*Ken Mayer* [dBVIPS]
/Golden Stag Productions/
dBASE at goldenstag dot net
http://www.goldenstag.net/GSP
http://www.goldenstag.net/dbase
| |
| Kathy Kolosky 2005-09-12, 8:24 pm |
| Done!
- Kathy
"Ken Mayer [dBVIPS]" < dbase@_nospam_golden
stag.net> wrote in message
news:84q1SY9tFHA.1232@news-server...
> Kathy Kolosky wrote:
>
> You might want to add to this the ability to determine if any text is
> selected (so you could enable/disable buttons, and so on ...).
>
> Ken
>
> --
> /(Opinions expressed are purely my own, not those of dataBased
> Intelligence, Inc.)/
>
> *Ken Mayer* [dBVIPS]
> /Golden Stag Productions/
> dBASE at goldenstag dot net
> http://www.goldenstag.net/GSP
> http://www.goldenstag.net/dbase
|
|
|
|
|