2.5: Text Editor back.

There was very little structure in this code, using many globals
and duplicated code. Now it should be better structured. Most
things should work, the main parts that are not back yet are the
python plugins and markers. Notes:

* Blenfont is used for drawing the text, nicely anti-aliased.
* A monospace truetype font was added, since that is needed for
  the text editor. It's Bitstream Vera Sans Mono. This is the
  default gnome terminal font, but it doesn't fit entirely well
  with the other font I think, can be changed easily of course.

* Clipboard copy/cut/paste now always uses the system clipboard,
  the code for the own cut buffer was removed.
* The interface buttons should support copy/cut/paste again now
  as well.
* WM_clipboard_text_get/WM_clipboard_text_set were added to the
  windowmanager code.

* Find panel is now a kind of second header, instead of a panel.
  This needs especially a way to start editing the text field
  immediately on open still.

* Operators are independent of the actual space when possible,
  was a bit of puzzling but got it solved nice with notifiers,
  and some lazy init for syntax highlight in the drawing code.
* RNA was created for the text editor space and used for buttons.

* Operators:
    * New, Open, Reload, Save, Save As, Make Internal
    * Run Script, Refresh Pyconstraints
    * Copy, Cut, Paste
    * Convert Whitespace, Uncomment, Comment, Indent, Unindent
    * Line Break, Insert
    * Next Marker, Previous Marker, Clear All Markers, Mark All
    * Select Line, Select All
    * Jump, Move, Move Select, Delete, Toggle Overwrite
	* Scroll, Scroll Bar, Set Cursor, Line Number
    * Find and Replace, Find, Replace, Find Set Selected,
	  Replace Set Selected
    * To 3D Object
    * Resolve Conflict
This commit is contained in:
Brecht Van Lommel
2009-02-28 23:33:35 +00:00
parent 2469305376
commit 6cc89b9d4e
49 changed files with 15483 additions and 425 deletions

View File

@@ -771,14 +771,16 @@ extern GHOST_TSuccess GHOST_ClipRectangle(GHOST_RectangleHandle rectanglehandle,
/**
* Return the data from the clipboad
* @return clipboard data
* @param return the selection instead, X11 only feature
* @return clipboard data
*/
extern GHOST_TUns8* GHOST_getClipboard(int flag);
extern GHOST_TUns8* GHOST_getClipboard(int selection);
/**
* Put data to the Clipboard
* @param set the selection instead, X11 only feature
*/
extern void GHOST_putClipboard(GHOST_TInt8 *buffer, int flag);
extern void GHOST_putClipboard(GHOST_TInt8 *buffer, int selection);
#ifdef __cplusplus
}