- Added initialize to '4' for new tab variable in text window

(prevents crash reported by sgefant!)
- Selection outline for Curve objects didnt draw right after leave
  editmode
- outliner now default when first viewing Oops window (dangerous?)
- Zoom with ctrl+middlemouse works in Oops again
This commit is contained in:
Ton Roosendaal 2004-11-01 20:50:42 +00:00
parent 9a5f98576a
commit cae8b8783d
6 changed files with 20 additions and 5 deletions

@ -96,7 +96,9 @@ void indent (struct Text *text, char *in_buffer);
void unindent_lines (struct Text *text, char *in_buffer); void unindent_lines (struct Text *text, char *in_buffer);
void comment_paste (struct Text *text, char *in_buffer); void comment_paste (struct Text *text, char *in_buffer);
void uncomment_paste (struct Text *text, char *in_buffer); void uncomment_paste (struct Text *text, char *in_buffer);
//void set_tabs (struct Text *text); void uncomment (struct Text *text);
//void set_tabs (struct Text *text);
/* Undo opcodes */ /* Undo opcodes */

@ -403,7 +403,7 @@ int displist_has_faces(ListBase *lb)
dl= lb->first; dl= lb->first;
while(dl) { while(dl) {
if ELEM5(dl->type, DL_INDEX3, DL_INDEX4, DL_SURF, DL_MESH, DL_TRIA) if ELEM6(dl->type, DL_INDEX3, DL_INDEX4, DL_SURF, DL_MESH, DL_TRIA, DL_POLY)
return 1; return 1;
dl= dl->next; dl= dl->next;
} }

@ -4527,6 +4527,10 @@ static void do_versions(Main *main)
View3D *v3d= (View3D *)sl; View3D *v3d= (View3D *)sl;
if(set_zbuf_sel) v3d->flag |= V3D_ZBUF_SELECT; if(set_zbuf_sel) v3d->flag |= V3D_ZBUF_SELECT;
} }
else if(sl->spacetype==SPACE_TEXT) {
SpaceText *st= (SpaceText *)sl;
if(st->tabnumber==0) st->tabnumber= 2;
}
} }
} }
} }

@ -1929,7 +1929,14 @@ int view2dmove(unsigned short event)
if ( (G.qual & LR_CTRLKEY) || (event==WHEELUPMOUSE) || (event==WHEELDOWNMOUSE) ) { if ( (G.qual & LR_CTRLKEY) || (event==WHEELUPMOUSE) || (event==WHEELDOWNMOUSE) ) {
/* patch for oops & buttonswin, standard scroll no zoom */ /* patch for oops & buttonswin, standard scroll no zoom */
if(curarea->spacetype==SPACE_OOPS); if(curarea->spacetype==SPACE_OOPS) {
SpaceOops *soops= curarea->spacedata.first;
if(soops->type==SO_OUTLINER);
else if (view2dzoom(event)) {
curarea->head_swap= 0;
return 0;
}
}
else if(curarea->spacetype==SPACE_BUTS && (G.qual & LR_CTRLKEY)==0); else if(curarea->spacetype==SPACE_BUTS && (G.qual & LR_CTRLKEY)==0);
else if (view2dzoom(event)) { else if (view2dzoom(event)) {
curarea->head_swap= 0; curarea->head_swap= 0;

@ -569,9 +569,10 @@ void text_buttons(void)
xco+=XIC; xco+=XIC;
if(st->font_id>1) st->font_id= 0; if(st->font_id>1) st->font_id= 0;
uiDefButI(block, MENU, B_TEXTFONT, "Screen 12 %x0|Screen 15%x1", xco,0,100,YIC, &st->font_id, 0, 0, 0, 0, "Displays available fonts"); uiDefButI(block, MENU, B_TEXTFONT, "Screen 12 %x0|Screen 15%x1", xco,0,100,YIC, &st->font_id, 0, 0, 0, 0, "Displays available fonts");
xco+=100; xco+=110;
uiDefButI(block, NUM, B_TAB_NUMBERS, "Tab:", xco+=XIC, 0, XIC+50, YIC, &st->tabnumber, 2, 8, 0, 0, "Set spacing of Tab"); uiDefButI(block, NUM, B_TAB_NUMBERS, "Tab:", xco, 0, XIC+50, YIC, &st->tabnumber, 2, 8, 0, 0, "Set spacing of Tab");
xco+= XIC+50;
/* always as last */ /* always as last */
curarea->headbutlen= xco+2*XIC; curarea->headbutlen= xco+2*XIC;

@ -4031,6 +4031,7 @@ static void init_oopsspace(ScrArea *sa, int outliner)
if(outliner) soops->type= SO_OUTLINER; if(outliner) soops->type= SO_OUTLINER;
soops->spacetype= SPACE_OOPS; soops->spacetype= SPACE_OOPS;
soops->type= SO_OUTLINER; // default starts new ones in outliner mode
soops->blockscale= 0.7; soops->blockscale= 0.7;
init_v2d_oops(sa, soops); init_v2d_oops(sa, soops);
} }