===================================================== Liste_Funktionen_Beginn: GUI_Ed_getLsta get ZeilenStartPos as Offset GUI_Ed_getLend get ZeilenEndPos as Offset GUI_Ed_getLpos get ZeilenStart/EndPos as Offsets GUI_Ed_getEof get EOF-Position as Offset GUI_Ed_getCpos get Cursorposition as Offset GUI_Ed_getLnr get LineNr of act.Curpos GUI_Ed_setCpos Cursorposition setzen (= implizites unselect) GUI_Ed_setCnxtL Cursorposition auf next Line setzen GUI_Ed_scroll_u scroll to curPos (= implizites unselect) GUI_Ed_scroll_s scroll to curPos (= selected) GUI_Ed_sel__ select_region GUI_Ed_sel_ln select Line, set Curpos to Line. GUI_Ed_Insert Text einfuegen GUI_Ed_Ins_f Inhalt einer Datei einfuegen und selected setzen GUI_Ed_Write das gesamte Editfenster neu schreiben (txbuf -> Window) GUI_Ed_RdChr read char near cursor GUI_Ed_RdLnAct die aktuelle Zeile einlesen GUI_Ed_Read Den Windowinhalt -> txbuf kopieren. GUI_Ed_sel_wrf write selected text -> file GUI_Ed_sel_del delete select_region GUI_Ed_del delete Bereich von - bis GUI_Ed_Init Create ein Editfenster. GUI_Ed_Init1 get attributes of Editwindow (textsize, ..) GUI_Ed_Focus den Focus auf EditWindopw GUI_Ed_editable editabel or frozen .. GUI_Ed_update_txt refresh txt Liste_Funktionen_Ende: =====================================================
#include "../xa/MS_Def0.h"
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "../gtk/ut_gtk.h"
#include "../gtk/ut_gtkEd.h"
#include "../ut/ut_txfil.h"
Functions | |
int | GUI_Ed_editable (GIO_WinEd *wTx, int mode) |
int | GUI_Ed_getLsta (GIO_WinEd *wTx, int cPos) |
int | GUI_Ed_getLend (GIO_WinEd *wTx, int cPos) |
long | GUI_Ed_getEof (GIO_WinEd *wTx) |
int | GUI_Ed_getLnr (GIO_WinEd *wTx) |
long | GUI_Ed_getCpos (GIO_WinEd *wTx) |
int | GUI_Ed_setLnr (GIO_WinEd *wTx, long lNr) |
int | GUI_Ed_setCpos (GIO_WinEd *wTx, long cpos) |
int | GUI_Ed_setCnxtL (GIO_WinEd *wTx) |
int | GUI_Ed_getLpos (int *sPos, int *ePos, int cPos, GIO_WinEd *wTx) |
int | GUI_Ed_scroll_u (GIO_WinEd *wTx, int cPos) |
int | GUI_Ed_scroll_s (GIO_WinEd *wTx) |
int | GUI_Ed_sel__ (GIO_WinEd *wTx, int von, int bis) |
int | GUI_Ed_sel_ln (GIO_WinEd *wTx, long lNr) |
int | GUI_Ed_sel_del (GIO_WinEd *wTx) |
int | GUI_Ed_del (GIO_WinEd *wTx, int von, int bis) |
int | GUI_Ed_sel_wrf (GIO_WinEd *wTx, char *fnam) |
int | GUI_Ed_Insert (GIO_WinEd *wTx, int cpos, char *txbuf, long txlen) |
char | GUI_Ed_RdChr (GIO_WinEd *wTx, int offset) |
int | GUI_Ed_RdLnAct (GIO_WinEd *wTx, char *txbuf, int *txlen) |
int | GUI_Ed_Ins_f (GIO_WinEd *wTx, char *fnam) |
int | GUI_Ed_Read (GIO_WinEd *wTx, char *txbuf, long *txlen) |
int | GUI_Ed_update_txt (GIO_WinEd *wTx, long cpos) |
int | GUI_Ed_Write (GIO_WinEd *wTx, char *txbuf, long *txlen, long maxlen) |
void | GUI_Ed_Focus (GIO_WinEd *wTx) |
void | GUI_Ed_Init (GIO_WinEd *wTx, void *funcnam, int mode) |
void | GUI_Ed_Init1 (GIO_WinEd *wTx) |
Variables | |
static int | UI_Ed_ln_sizY |
static float | UI_Ed_ln_offY |
static char * | UI_Ed_lcSet |
int GUI_Ed_editable | ( | GIO_WinEd * | wTx, | |
int | mode | |||
) |
GUI_Ed_editable editabel or frozen .. mode: FALSE = 0 TRUE = 1 ACHTUNG: tw abhaengig vom style; see UI_win_main/UI_styl_1
long GUI_Ed_getEof | ( | GIO_WinEd * | wTx | ) |
GUI_Ed_getEof get FileSize (EOF-Position)
int GUI_Ed_getLnr | ( | GIO_WinEd * | wTx | ) |
GUI_Ed_getLnr get LineNr of act.Curpos ACHTUNG: use always GUI_Ed_getLnr (not GUI_Ed_getLnr); die Filesize und cPos ist unterschiedlich, weil gtk Sonderzeichen nur als 1 char behandelt !!! Man darf daher die cPos nicht zum Positionieren im Mem benutzen !!!!
long GUI_Ed_getCpos | ( | GIO_WinEd * | wTx | ) |
int GUI_Ed_setLnr | ( | GIO_WinEd * | wTx, | |
long | lNr | |||
) |
int GUI_Ed_setCpos | ( | GIO_WinEd * | wTx, | |
long | cpos | |||
) |
Cursorposition setzen und Focus auf EditWin
int GUI_Ed_getLpos | ( | int * | sPos, | |
int * | ePos, | |||
int | cPos, | |||
GIO_WinEd * | wTx | |||
) |
int GUI_Ed_scroll_u | ( | GIO_WinEd * | wTx, | |
int | cPos | |||
) |
impliziert unselect
int GUI_Ed_scroll_s | ( | GIO_WinEd * | wTx | ) |
macht leider ein unselect !!
int GUI_Ed_sel__ | ( | GIO_WinEd * | wTx, | |
int | von, | |||
int | bis | |||
) |
select_region von cpos bis cpos (und scroll!) if(von < 0) - unsect all !
int GUI_Ed_sel_ln | ( | GIO_WinEd * | wTx, | |
long | lNr | |||
) |
GUI_Ed_sel_ln select Line, set Curpos to Line. Erste Zeile ist 1 rc -1: lNr does not exist ACHTUNG: die ZeilenStart/Endposition wird aus dem mem gelesen !!!!
int GUI_Ed_sel_del | ( | GIO_WinEd * | wTx | ) |
delete selected text
int GUI_Ed_del | ( | GIO_WinEd * | wTx, | |
int | von, | |||
int | bis | |||
) |
int GUI_Ed_sel_wrf | ( | GIO_WinEd * | wTx, | |
char * | fnam | |||
) |
write selected -> file returns nr of chars
int GUI_Ed_Insert | ( | GIO_WinEd * | wTx, | |
int | cpos, | |||
char * | txbuf, | |||
long | txlen | |||
) |
char GUI_Ed_RdChr | ( | GIO_WinEd * | wTx, | |
int | offset | |||
) |
read char near cursor; offset 0 = char right of cursor offset -1 = char left of cursor
int GUI_Ed_RdLnAct | ( | GIO_WinEd * | wTx, | |
char * | txbuf, | |||
int * | txlen | |||
) |
die aktuelle Zeile aus dem Editor einlesen
int GUI_Ed_Ins_f | ( | GIO_WinEd * | wTx, | |
char * | fnam | |||
) |
GUI_Ed_Ins_f Inhalt einer datei einfuegen und selected setzen.
int GUI_Ed_Read | ( | GIO_WinEd * | wTx, | |
char * | txbuf, | |||
long * | txlen | |||
) |
int GUI_Ed_update_txt | ( | GIO_WinEd * | wTx, | |
long | cpos | |||
) |
make Displayupdate;
int GUI_Ed_Write | ( | GIO_WinEd * | wTx, | |
char * | txbuf, | |||
long * | txlen, | |||
long | maxlen | |||
) |
das gesamte Editfenster neu schreiben (txbuf(=mem) -> Window). ACHTUNG: GUI_Ed_Write kann txbuf veraendern ! (Umwandlung into UTF8)
void GUI_Ed_Focus | ( | GIO_WinEd * | wTx | ) |
den Focus auf EditWindow
void GUI_Ed_Init | ( | GIO_WinEd * | wTx, | |
void * | funcnam, | |||
int | mode | |||
) |
view for Focus text for all iterOper's win for packer mode = 0: kein Lineumbruch mode = 1: Lineumbruch funcnam = NULL od CallBackroutine for every char entered or removed GUI_Ed_Init (&winEd, NULL, 0); gtk_container_add (GTK_CONTAINER(box0), winED.win); gtk_widget_show (winED.win);
void GUI_Ed_Init1 | ( | GIO_WinEd * | wTx | ) |
GUI_Ed_Init1 get attributes of Editwindow (textsize, ..) ACHTUNG: changed: window nicht buffer !! geht erste nach gtk_widget_show
int UI_Ed_ln_sizY [static] |
float UI_Ed_ln_offY [static] |
char* UI_Ed_lcSet [static] |