WASTEfield 2.0 is a plugin replacement for Realbasic’s editfield control.
The changes & main features are listed below. Download from the rb folder:
New features in 2.0 and recent versions:
* Made Carbon/OS X compatible.
* I also altered the internal text engine to fix a longstanding background
color conflict with a few Realbasic controls. Please let me know if you
notice any new issues this created, I did not see any problems.
* Now has a Mousedown event, useful for adding contextual menu support:
if isCMMClick then
//for example, you might want to pass X&Y to GetOffset,
//then pass that to FindWord, then grab the word under the mouse.
return true //stop WASTE from handling the click
* Tab support: tabs as boolean and tabsize as integer properties.
* Group related changes into one undoable action:
Before your loop or your group of editing actions, call:
Then afterwards, call
Where X is some integer (between 1 & 12) that is just to tell Waste what
label to put in the Undo menu (see the demo or Waste.h for what each
number stands for).
* New accessors for PictString objects (picture + string):
GetPictString(offset as Integer) as String
SetPictString(offset as Integer, s as String)
Main Wastefield Features:
*Works in OS X as well as classic MacOS PPC.
*Embedded pictures, sounds, file objects…
*Paragraph alignment (center, left, right, justify).
*Multiple undo/redo support, built-in copy, cut, paste methods.
*More styles and attributes (strikethrough, backgroundcolor, line indent,
*Change or get text, text styles, sizes or colors without having to change
the current selection (Puttext, SetAtt… methods).
*Built-in printing, page setup methods, including Text2Pict.
*Built-in file loading/saving methods.
*Functions for finding words, lines, paragraphs.
*Methods for scrolling text vertically or horizontally, you can use for
making your own horizontal scrollbar. ScrollChanged event.
*Text can be wider than visible control, with line wrapping on or off.
*Convert mouse coordinates to text offsets and vice versa.
*Access to virtually all of WASTE 2.0 features, or disable any features
such as drag and drop, intelligent cut and paste, undo.
I’m also now asking for contributions of any amount to support work on the
plugin, but there are no restrictions on use of the plugin, and the source
is available on request as usual. I set up an Amazon paypage and soon a
Kagi account too to handle any contributions: