Blender  V3.3
text_autocomplete.c File Reference
#include <ctype.h>
#include <string.h>
#include "MEM_guardedalloc.h"
#include "DNA_text_types.h"
#include "BLI_blenlib.h"
#include "BLI_ghash.h"
#include "BKE_context.h"
#include "BKE_screen.h"
#include "BKE_text.h"
#include "BKE_text_suggestions.h"
#include "WM_api.h"
#include "WM_types.h"
#include "ED_screen.h"
#include "ED_text.h"
#include "ED_undo.h"
#include "UI_interface.h"
#include "text_format.h"
#include "text_intern.h"

Go to the source code of this file.

Functions

Public API
bool text_do_suggest_select (SpaceText *st, ARegion *region, const int mval[2])
 
void text_pop_suggest_list (void)
 
Private API
static void text_autocomplete_free (bContext *C, wmOperator *op)
 
static GHashtext_autocomplete_build (Text *text)
 
static void get_suggest_prefix (Text *text, int offset)
 
static void confirm_suggestion (Text *text)
 

Auto Complete Operator

static int doc_scroll = 0
 
static int text_autocomplete_invoke (bContext *C, wmOperator *op, const wmEvent *UNUSED(event))
 
static int text_autocomplete_modal (bContext *C, wmOperator *op, const wmEvent *event)
 
static void text_autocomplete_cancel (bContext *C, wmOperator *op)
 
void TEXT_OT_autocomplete (wmOperatorType *ot)
 

Function Documentation

◆ confirm_suggestion()

static void confirm_suggestion ( Text text)
static

◆ get_suggest_prefix()

static void get_suggest_prefix ( Text text,
int  offset 
)
static

◆ text_autocomplete_build()

static GHash* text_autocomplete_build ( Text text)
static

◆ text_autocomplete_cancel()

static void text_autocomplete_cancel ( bContext C,
wmOperator op 
)
static

Definition at line 599 of file text_autocomplete.c.

References C, and text_autocomplete_free().

Referenced by TEXT_OT_autocomplete().

◆ text_autocomplete_free()

static void text_autocomplete_free ( bContext C,
wmOperator op 
)
static

◆ text_autocomplete_invoke()

static int text_autocomplete_invoke ( bContext C,
wmOperator op,
const wmEvent UNUSEDevent 
)
static

◆ text_autocomplete_modal()

static int text_autocomplete_modal ( bContext C,
wmOperator op,
const wmEvent event 
)
static

◆ text_do_suggest_select()

bool text_do_suggest_select ( SpaceText st,
ARegion region,
const int  mval[2] 
)

◆ TEXT_OT_autocomplete()

void TEXT_OT_autocomplete ( wmOperatorType ot)

◆ text_pop_suggest_list()

void text_pop_suggest_list ( void  )

Variable Documentation

◆ doc_scroll

int doc_scroll = 0
static

Definition at line 313 of file text_autocomplete.c.

Referenced by text_autocomplete_modal().