Blender  V2.93
Functions | Variables
space_text.c File Reference
#include <string.h>
#include "DNA_text_types.h"
#include "MEM_guardedalloc.h"
#include "BLI_blenlib.h"
#include "BKE_context.h"
#include "BKE_global.h"
#include "BKE_lib_id.h"
#include "BKE_screen.h"
#include "ED_screen.h"
#include "ED_space_api.h"
#include "WM_api.h"
#include "WM_types.h"
#include "UI_interface.h"
#include "UI_resources.h"
#include "UI_view2d.h"
#include "RNA_access.h"
#include "text_format.h"
#include "text_intern.h"

Go to the source code of this file.

Functions

static SpaceLinktext_create (const ScrArea *UNUSED(area), const Scene *UNUSED(scene))
 
static void text_free (SpaceLink *sl)
 
static void text_init (struct wmWindowManager *UNUSED(wm), ScrArea *UNUSED(area))
 
static SpaceLinktext_duplicate (SpaceLink *sl)
 
static void text_listener (const wmSpaceTypeListenerParams *params)
 
static void text_operatortypes (void)
 
static void text_keymap (struct wmKeyConfig *keyconf)
 
static int text_context (const bContext *C, const char *member, bContextDataResult *result)
 
static void text_main_region_init (wmWindowManager *wm, ARegion *region)
 
static void text_main_region_draw (const bContext *C, ARegion *region)
 
static void text_cursor (wmWindow *win, ScrArea *area, ARegion *region)
 
static bool text_drop_poll (bContext *UNUSED(C), wmDrag *drag, const wmEvent *UNUSED(event), const char **UNUSED(r_tooltip))
 
static void text_drop_copy (wmDrag *drag, wmDropBox *drop)
 
static bool text_drop_paste_poll (bContext *UNUSED(C), wmDrag *drag, const wmEvent *UNUSED(event), const char **UNUSED(r_tooltip))
 
static void text_drop_paste (wmDrag *drag, wmDropBox *drop)
 
static void text_dropboxes (void)
 
static void text_header_region_init (wmWindowManager *UNUSED(wm), ARegion *region)
 
static void text_header_region_draw (const bContext *C, ARegion *region)
 
static void text_properties_region_init (wmWindowManager *wm, ARegion *region)
 
static void text_properties_region_draw (const bContext *C, ARegion *region)
 
static void text_id_remap (ScrArea *UNUSED(area), SpaceLink *slink, ID *old_id, ID *new_id)
 
void ED_spacetype_text (void)
 

Variables

const char * text_context_dir [] = {"edit_text", NULL}
 

Function Documentation

◆ ED_spacetype_text()

void ED_spacetype_text ( void  )

◆ text_context()

static int text_context ( const bContext C,
const char *  member,
bContextDataResult result 
)
static

◆ text_create()

static SpaceLink* text_create ( const ScrArea UNUSEDarea,
const Scene UNUSEDscene 
)
static

◆ text_cursor()

static void text_cursor ( wmWindow win,
ScrArea area,
ARegion region 
)
static

◆ text_drop_copy()

static void text_drop_copy ( wmDrag drag,
wmDropBox drop 
)
static

Definition at line 329 of file space_text.c.

References wmDrag::path, wmDropBox::ptr, and RNA_string_set().

Referenced by text_dropboxes().

◆ text_drop_paste()

static void text_drop_paste ( wmDrag drag,
wmDropBox drop 
)
static

◆ text_drop_paste_poll()

static bool text_drop_paste_poll ( bContext UNUSEDC,
wmDrag drag,
const wmEvent UNUSEDevent,
const char **  UNUSEDr_tooltip 
)
static

Definition at line 335 of file space_text.c.

References wmDrag::type, and WM_DRAG_ID.

Referenced by text_dropboxes().

◆ text_drop_poll()

static bool text_drop_poll ( bContext UNUSEDC,
wmDrag drag,
const wmEvent UNUSEDevent,
const char **  UNUSEDr_tooltip 
)
static

Definition at line 315 of file space_text.c.

References ELEM, wmDrag::icon, wmDrag::type, and WM_DRAG_PATH.

Referenced by text_dropboxes().

◆ text_dropboxes()

static void text_dropboxes ( void  )
static

◆ text_duplicate()

static SpaceLink* text_duplicate ( SpaceLink sl)
static

Definition at line 112 of file space_text.c.

References SpaceText_Runtime::drawcache, MEM_dupallocN, NULL, and SpaceText::runtime.

Referenced by ED_spacetype_text().

◆ text_free()

static void text_free ( SpaceLink sl)
static

Definition at line 99 of file space_text.c.

References NULL, SpaceText::text, and text_free_caches().

Referenced by ED_spacetype_text(), and make_duplis_font().

◆ text_header_region_draw()

static void text_header_region_draw ( const bContext C,
ARegion region 
)
static

Definition at line 373 of file space_text.c.

References C, and ED_region_header().

Referenced by ED_spacetype_text().

◆ text_header_region_init()

static void text_header_region_init ( wmWindowManager UNUSEDwm,
ARegion region 
)
static

Definition at line 368 of file space_text.c.

References ED_region_header_init().

Referenced by ED_spacetype_text().

◆ text_id_remap()

static void text_id_remap ( ScrArea UNUSEDarea,
SpaceLink slink,
ID old_id,
ID new_id 
)
static

Definition at line 410 of file space_text.c.

References ELEM, GS, ID_TXT, id_us_ensure_real(), ID::name, and SpaceText::text.

Referenced by ED_spacetype_text().

◆ text_init()

static void text_init ( struct wmWindowManager UNUSEDwm,
ScrArea UNUSEDarea 
)
static

Definition at line 108 of file space_text.c.

Referenced by ED_spacetype_text().

◆ text_keymap()

static void text_keymap ( struct wmKeyConfig keyconf)
static

Definition at line 229 of file space_text.c.

References SPACE_TEXT, and WM_keymap_ensure().

Referenced by ED_spacetype_text().

◆ text_listener()

static void text_listener ( const wmSpaceTypeListenerParams params)
static

◆ text_main_region_draw()

static void text_main_region_draw ( const bContext C,
ARegion region 
)
static

Definition at line 279 of file space_text.c.

References C, CTX_wm_space_text(), draw_text_main(), TH_BACK, and UI_ThemeClearColor().

Referenced by ED_spacetype_text().

◆ text_main_region_init()

static void text_main_region_init ( wmWindowManager wm,
ARegion region 
)
static

◆ text_operatortypes()

static void text_operatortypes ( void  )
static

◆ text_properties_region_draw()

static void text_properties_region_draw ( const bContext C,
ARegion region 
)
static

◆ text_properties_region_init()

static void text_properties_region_init ( wmWindowManager wm,
ARegion region 
)
static

Variable Documentation

◆ text_context_dir

const char* text_context_dir[] = {"edit_text", NULL}

Definition at line 235 of file space_text.c.

Referenced by text_context().