- further work on theme colors:
authorTon Roosendaal <ton@blender.org>
Fri, 17 Oct 2003 23:18:18 +0000 (23:18 +0000)
committerTon Roosendaal <ton@blender.org>
Fri, 17 Oct 2003 23:18:18 +0000 (23:18 +0000)
  - panels work
  - ipo window done
  - buttonswindow done

Please be warned that saving  Themes now wont work... it will also save
BLACK for all uninitalized colors... so dont panic when you see weird
things, just go back the default theme and copy a new one.

source/blender/makesdna/DNA_sound_types.h
source/blender/makesdna/DNA_userdef_types.h
source/blender/src/butspace.c
source/blender/src/drawipo.c
source/blender/src/drawsound.c
source/blender/src/editsound.c
source/blender/src/interface_panel.c
source/blender/src/resources.c
source/blender/src/space.c

index 31f8526907b7e552acb14963bde0afe971e012df..aa6a6576758c6958d310ce20fb9eace5575107df 100644 (file)
@@ -133,6 +133,7 @@ typedef struct bSoundListener {
 
 /* spacesound->flag */
 #define SND_DRAWFRAMES 1
+#define SND_CFRA_NUM   2
 
 typedef struct SpaceSound {
        struct SpaceLink *next, *prev;
index e9129ca368d178b8a3186fd1ea5d3340031d17fc..1c7bdc87d1ad84a8b5314e2b3a316efc64980e22 100644 (file)
@@ -82,6 +82,15 @@ typedef struct bTheme {
        ThemeSpace tv3d;
        ThemeSpace tfile;
        ThemeSpace tipo;
+       ThemeSpace tinfo;       
+       ThemeSpace tsnd;
+       ThemeSpace tact;
+       ThemeSpace tnla;
+       ThemeSpace tseq;
+       ThemeSpace tima;
+       ThemeSpace timasel;
+       ThemeSpace text;
+       ThemeSpace toops;
        
 } bTheme;
 
index b17156057e2aa414805731ee0dcd081e3d83fdc8..bd443ec1bb8ebdce8b495418c4b67cac1faedacd 100644 (file)
@@ -373,11 +373,13 @@ void drawbutspace(ScrArea *sa, void *spacedata)
 {
        SpaceButs *sbuts= sa->spacedata.first;
        View2D *v2d= &sbuts->v2d;
+       float col[3];
        int tab, align=0;
        
        myortho2(v2d->cur.xmin, v2d->cur.xmax, v2d->cur.ymin, v2d->cur.ymax);
 
-       glClearColor(0.73, 0.73, 0.73, 0.0);
+       BIF_GetThemeColor3fv(sa, TH_BACK, col);
+       glClearColor(col[0], col[1], col[2], 0.0); 
        glClear(GL_COLOR_BUFFER_BIT);
 
        uiSetButLock(G.scene->id.lib!=0, "Can't edit library data");    
index a959a8421b46cb7a578692e1bcf00551bfd9342e..a52157c4b56da2ae81067cf656c5cbff25b323fe 100644 (file)
@@ -206,7 +206,7 @@ void draw_ipogrid(void)
        step= (G.v2d->mask.xmax-G.v2d->mask.xmin+1)/IPOSTEP;
        
        if(curarea->spacetype==SPACE_SOUND) glColor3ub(0x70, 0x70, 0x60);
-       else glColor3ub(0x40, 0x40, 0x40);
+       else BIF_ThemeColor(curarea, TH_GRID);
        
        for(a=0; a<step; a++) {
                glBegin(GL_LINE_STRIP);
@@ -218,7 +218,7 @@ void draw_ipogrid(void)
        vec2[0]= vec1[0]-= 0.5*ipogrid_dx;
        
        if(curarea->spacetype==SPACE_SOUND) glColor3ub(0x80, 0x80, 0x70);
-       else glColor3ub(0x50, 0x50, 0x50);
+       else  BIF_ThemeColorShade(curarea, TH_GRID, 16);
        
        step++;
        for(a=0; a<=step; a++) {
@@ -235,7 +235,7 @@ void draw_ipogrid(void)
                
                step= (curarea->winy+1)/IPOSTEP;
                
-               glColor3ub(0x40, 0x40, 0x40);
+               BIF_ThemeColor(curarea, TH_GRID);
                for(a=0; a<=step; a++) {
                        glBegin(GL_LINE_STRIP);
                        glVertex2fv(vec1); glVertex2fv(vec2);
@@ -246,7 +246,7 @@ void draw_ipogrid(void)
                step++;
                
                if(curarea->spacetype==SPACE_IPO) {
-                       glColor3ub(0x50, 0x50, 0x50);
+                       BIF_ThemeColorShade(curarea, TH_GRID, 16);
                        for(a=0; a<step; a++) {
                                glBegin(GL_LINE_STRIP);
                                glVertex2fv(vec1); glVertex2fv(vec2);
@@ -256,7 +256,7 @@ void draw_ipogrid(void)
                }
        }
        
-       glColor3ub(0, 0, 0);
+       BIF_ThemeColorShade(curarea, TH_GRID, -50);
        
        if (curarea->spacetype!=SPACE_ACTION && curarea->spacetype!=SPACE_NLA)
        {       /* Horizontal axis */
@@ -603,18 +603,19 @@ void drawscroll(int disptype)
 {
        rcti vert, hor;
        float fac, dfac, val, fac2, tim;
-       unsigned int darker, dark, light, lighter;
+       int darker, dark, light, lighter;
        
        vert= (G.v2d->vert);
        hor= (G.v2d->hor);
        
-       darker= 0x404040;
-       dark= 0x858585;
-       light= 0x989898;
-       lighter= 0xc0c0c0;
+       darker= -40;
+       dark= 0;
+       light= 20;
+       lighter= 50;
        
        if(G.v2d->scroll & HOR_SCROLL) {
-               cpack(light);
+               
+               BIF_ThemeColorShade(curarea, TH_SHADE1, light);
                glRecti(hor.xmin,  hor.ymin,  hor.xmax,  hor.ymax);
                
                /* slider */
@@ -628,11 +629,11 @@ void drawscroll(int disptype)
                
                if(horxmin > horxmax) horxmin= horxmax;
                
-               cpack(dark);
+               BIF_ThemeColorShade(curarea, TH_SHADE1, dark);
                glRecti(horxmin,  hor.ymin,  horxmax,  hor.ymax);
 
                /* decoration bright line */
-               cpack(lighter);
+               BIF_ThemeColorShade(curarea, TH_SHADE1, lighter);
                sdrawline(hor.xmin, hor.ymax, hor.xmax, hor.ymax);
 
                /* the numbers: convert ipogrid_startx and -dx to scroll coordinates */
@@ -642,7 +643,7 @@ void drawscroll(int disptype)
                dfac= (ipogrid_dx)/(G.v2d->cur.xmax-G.v2d->cur.xmin);
                dfac= dfac*(hor.xmax-hor.xmin);
                
-               glColor3ub(0, 0, 0);
+               BIF_ThemeColor(curarea, TH_TEXT);
                val= ipogrid_startx;
                while(fac < hor.xmax) {
                        
@@ -674,9 +675,8 @@ void drawscroll(int disptype)
        }
        
        if(G.v2d->scroll & VERT_SCROLL) {
-               cpack(light);
+               BIF_ThemeColorShade(curarea, TH_SHADE1, light);
                glRecti(vert.xmin,  vert.ymin,  vert.xmax,  vert.ymax);
-               glColor3ub(0, 0, 0);
                
                /* slider */
                fac= (G.v2d->cur.ymin- G.v2d->tot.ymin)/(G.v2d->tot.ymax-G.v2d->tot.ymin);
@@ -689,11 +689,11 @@ void drawscroll(int disptype)
                
                if(vertymin > vertymax) vertymin= vertymax;
                
-               cpack(dark);
+               BIF_ThemeColorShade(curarea, TH_SHADE1, dark);
                glRecti(vert.xmin,  vertymin,  vert.xmax,  vertymax);
 
                /* decoration black line */
-               cpack(darker);
+               BIF_ThemeColorShade(curarea, TH_SHADE1, darker);
                if(G.v2d->scroll & HOR_SCROLL) 
                        sdrawline(vert.xmax, vert.ymin+SCROLLH, vert.xmax, vert.ymax);
                else 
@@ -707,7 +707,7 @@ void drawscroll(int disptype)
                dfac= dfac*(vert.ymax-vert.ymin-SCROLLH);
                
                if(curarea->spacetype==SPACE_SEQ) {
-                       glColor3ub(0, 0, 0);
+                       BIF_ThemeColor(curarea, TH_TEXT);
                        val= ipogrid_starty;
                        fac+= 0.5*dfac;
                        while(fac < vert.ymax) {
@@ -722,7 +722,7 @@ void drawscroll(int disptype)
                        /* No digits on vertical axis in action mode! */
                }
                else {
-                       glColor3ub(0, 0, 0);
+                       BIF_ThemeColor(curarea, TH_TEXT);
                        val= ipogrid_starty;
                        while(fac < vert.ymax) {
                                scroll_prstr((float)(vert.xmax)-14.0, fac, val, 'v', disptype);
@@ -750,8 +750,7 @@ static void draw_ipobuts(SpaceIpo *sipo)
                if(tot<area->winy) sipo->butofs= 0;
        }
        
-       glColor3ub(0x7f, 0x70, 0x70);
-       
+       BIF_ThemeColor(curarea, TH_SHADE2);
        glRects(v2d->mask.xmax,  0,  area->winx,  area->winy);
        
        cpack(0x0);
@@ -830,7 +829,6 @@ static void draw_ipovertices(int sel)
        EditIpo *ei;
        BezTriple *bezt;
        float v1[2];
-       unsigned int col;
        int val, ok, nr, a, b;
        
        if(G.f & G_PICKSEL) return;
@@ -842,17 +840,18 @@ static void draw_ipovertices(int sel)
                if ISPOIN(ei, flag & IPO_VISIBLE, icu) {
                        
                        if(G.sipo->showkey) {
-                               if(sel) col= 0xFFFFFF; else col= 0x0;
+                               if(sel) BIF_ThemeColor(curarea, TH_TEXT_HI);
+                                else BIF_ThemeColor(curarea, TH_TEXT);
                        } else if(ei->flag & IPO_EDIT) {
-                               if(sel) col= 0x77FFFF; else col= 0xFF70FF;
+                               if(sel) BIF_ThemeColor(curarea, TH_VERTEX_SELECT); 
+                               else BIF_ThemeColor(curarea, TH_VERTEX);
                        } else {
-                               if(sel) col= 0xFFFFFF; else col= 0x0;
+                               if(sel) BIF_ThemeColor(curarea, TH_TEXT_HI);
+                                else BIF_ThemeColor(curarea, TH_TEXT);
+                                
                                val= (ei->icu->flag & IPO_SELECT)!=0;
                                if(sel != val) continue;
                        }
-                       
-                       cpack(col);
-
 
                        /* We can't change the color in the middle of
                         * GL_POINTS because then Blender will segfault
@@ -1009,7 +1008,8 @@ static void draw_ipocurves(int sel)
                                icu= ei->icu;   
                                
                                /* curve */
-                               if(G.sipo->showkey) glColor3ub(0, 0, 0); else cpack(ei->col);
+                               if(G.sipo->showkey) BIF_ThemeColor(curarea, TH_TEXT); 
+                               else cpack(ei->col);
                                
                                /* cyclic */
                                if(icu->extrap & IPO_CYCL) {
@@ -1204,7 +1204,7 @@ static void draw_cfra(SpaceIpo *sipo)
        vec[0]*= G.scene->r.framelen;
        
        vec[1]= v2d->cur.ymin;
-       glColor3ub(0x60, 0xc0, 0x40);
+       BIF_ThemeColor(curarea, TH_HILITE);
        glLineWidth(2.0);
        
        glBegin(GL_LINE_STRIP);
@@ -1218,7 +1218,7 @@ static void draw_cfra(SpaceIpo *sipo)
                if(ob && ob->sf!=0.0 && (ob->ipoflag & OB_OFFS_OB) ) {
                        vec[0]-= ob->sf;
                        
-                       glColor3ub(0x10, 0x60, 0);
+                       BIF_ThemeColorShade(curarea, TH_HILITE, -30);
                        
                        glBegin(GL_LINE_STRIP);
                        glVertex2fv(vec);
@@ -1303,16 +1303,19 @@ void drawipospace(ScrArea *sa, void *spacedata)
        SpaceIpo *sipo= curarea->spacedata.first;
        View2D *v2d= &sipo->v2d;
        EditIpo *ei;
+       float col[3];
        int ofsx, ofsy, a, disptype;
 
        v2d->hor.xmax+=IPOBUTX;
        calc_scrollrcts(G.v2d, curarea->winx, curarea->winy);
 
+       BIF_GetThemeColor3fv(sa, TH_BACK, col);
+       glClearColor(col[0], col[1], col[2], 0.0); 
 
        if (sipo->pin)
-               glClearColor(.45, .40, .40, 0.0);       // litepink
+               glClearColor(col[0]+0.05,col[1],col[2], 0.0);   // litepink
        else
-               glClearColor(.45, .45, .45, 0.0);
+               glClearColor(col[0],col[1],col[2], 0.0);
 
        glClear(GL_COLOR_BUFFER_BIT);
        
index 79bbcedc7032b0c56bab9541d5ee2c2d9424a2af..4b129e25d9d362e22cc8e41e09386f16af767236 100644 (file)
@@ -148,7 +148,7 @@ static void draw_cfra_sound(SpaceSound *ssound)
 {
        float vec[2];
        
-       if(get_mbut()&L_MOUSE) {
+       if(ssound->flag & SND_CFRA_NUM) {
                short mval[2];
                float x,  y;
                char str[32];
index 74d2086c8e9ce684edb26809abf67c9c9e18a29b..150a9eca289ceb01f354dc738997c3a65e8cfbb3 100644 (file)
@@ -113,7 +113,7 @@ void winqreadsoundspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
 
                switch(event) {
                case LEFTMOUSE:
-                       
+                       ssound->flag |= SND_CFRA_NUM;
                        do {
                                getmouseco_areawin(mval);
                                areamouseco_to_ipoco(G.v2d, mval, &dx, &dy);
@@ -130,6 +130,8 @@ void winqreadsoundspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
                                }
                        
                        } while(get_mbut()&L_MOUSE);
+                       ssound->flag &= ~SND_CFRA_NUM;
+                       
                        doredraw= 1;
 
                        break;
index 355e0fdae35c70f715488710f0ec04fd90024836..1535f360b5602c2878b6fb3d3a9a1c3e8cf82f29 100644 (file)
@@ -677,7 +677,7 @@ static void ui_draw_tria_icon(float x, float y, float aspect, char dir)
 {
 
        
-       glColor3ub(240, 240, 240);
+       BIF_ThemeColor(curarea, TH_TEXT_HI);
        
        if(dir=='h') {
                ui_draw_anti_tria( x, y, x, y+10.0, x+8.75, y+5.25);
@@ -685,8 +685,6 @@ static void ui_draw_tria_icon(float x, float y, float aspect, char dir)
        else {
                ui_draw_anti_tria( x-2, y+8.75,  x+10-2, y+8.75, x+5.25-2, y);  
        }
-       
-       
 }
 
 #if 0
@@ -758,7 +756,7 @@ static void ui_draw_panel_header(uiBlock *block)
        if(panel->control & UI_PNL_CLOSE) pnl_icons+= PNL_ICON;
 
        if(nr==1) {
-               glColor3ub(255,255,255);
+               BIF_ThemeColor(curarea, TH_TEXT_HI);
                glRasterPos2f(block->minx+pnl_icons, block->maxy+5);
                BIF_DrawString(block->curfont, block->panel->panelname, (U.transopts & TR_BUTTONS), 0);
                return;
@@ -772,10 +770,10 @@ static void ui_draw_panel_header(uiBlock *block)
                else if(pa==panel) {
                        /* active tab */
                        uiSetRoundBox(15);
-                       glColor3ub(140, 140, 147);
+                       BIF_ThemeColorShade(curarea, TH_HEADER, -60);
                        uiRoundBox(2+pnl_icons+a*width, panel->sizey+3, pnl_icons+(a+1)*width, panel->sizey+PNL_HEADER-3, 8);
 
-                       glColor3ub(255,255,255);
+                       BIF_ThemeColor(curarea, TH_TEXT_HI);
                        glRasterPos2f(10+pnl_icons+a*width, panel->sizey+5);
                        str= ui_block_cut_str(block, pa->panelname, (short)(width-10));
                        BIF_DrawString(block->curfont, str, (U.transopts & TR_BUTTONS), 0);
@@ -785,7 +783,7 @@ static void ui_draw_panel_header(uiBlock *block)
                else if(pa->paneltab==panel) {
                        /* not active tab */
                        
-                       glColor3ub(95,95,95);
+                       BIF_ThemeColorShade(curarea, TH_HEADER, -130);
                        glRasterPos2f(10+pnl_icons+a*width, panel->sizey+5);
                        str= ui_block_cut_str(block, pa->panelname, (short)(width-10));
                        BIF_DrawString(block->curfont, str, (U.transopts & TR_BUTTONS), 0);
@@ -797,7 +795,7 @@ static void ui_draw_panel_header(uiBlock *block)
        
        // dragger
        uiSetRoundBox(15);
-       glColor3ub(140, 140, 147);
+       BIF_ThemeColorShade(curarea, TH_HEADER, -70);
        uiRoundBox(panel->sizex-PNL_ICON+5, panel->sizey+5, panel->sizex-5, panel->sizey+PNL_HEADER-5, 5);
        
 }
@@ -816,23 +814,23 @@ void ui_draw_panel(uiBlock *block)
        
        if(panel->flag & PNL_CLOSEDY) {
                uiSetRoundBox(15);
-               BIF_ThemeColor(curarea, TH_HEADER);
+               BIF_ThemeColorShade(curarea, TH_HEADER, -30);
                uiRoundBox(block->minx, block->maxy, block->maxx, block->maxy+PNL_HEADER, 10);
                
                // title
                ofsx= 2*PNL_ICON;
                if(panel->control & UI_PNL_CLOSE) ofsx+= PNL_ICON;
-               glColor3ub(255,255,255);
+               BIF_ThemeColor(curarea, TH_TEXT_HI);
                glRasterPos2f(block->minx+40, block->maxy+5);
                BIF_DrawString(block->curfont, panel->panelname, (U.transopts & TR_BUTTONS), 0);
 
                //  border
                if(panel->flag & PNL_SELECT) {
-                       glColor3ub(64, 64, 64);
+                       BIF_ThemeColorShade(curarea, TH_HEADER, -120);
                        uiRoundRect(block->minx, block->maxy, block->maxx, block->maxy+PNL_HEADER, 10);
                }
                if(panel->flag & PNL_OVERLAP) {
-                       glColor3ub(240, 240, 240);
+                       BIF_ThemeColor(curarea, TH_TEXT_HI);
                        uiRoundRect(block->minx, block->maxy, block->maxx, block->maxy+PNL_HEADER, 10);
                }
        
@@ -842,11 +840,11 @@ void ui_draw_panel(uiBlock *block)
                int a, end, ofs;
                
                uiSetRoundBox(15);
-               BIF_ThemeColor(curarea, TH_HEADER);
+               BIF_ThemeColorShade(curarea, TH_HEADER, -30);
                uiRoundBox(block->minx, block->miny, block->minx+PNL_HEADER, block->maxy+PNL_HEADER, 10);
        
                // title, only capitals for now
-               glColor3ub(255,255,255);
+               BIF_ThemeColor(curarea, TH_TEXT_HI);
                str[1]= 0;
                end= strlen(panel->panelname);
                ofs= 20;
@@ -861,11 +859,11 @@ void ui_draw_panel(uiBlock *block)
                
                //  border
                if(panel->flag & PNL_SELECT) {
-                       glColor3ub(64, 64, 64);
+                       BIF_ThemeColorShade(curarea, TH_HEADER, -120);
                        uiRoundRect(block->minx, block->miny, block->minx+PNL_HEADER, block->maxy+PNL_HEADER, 10);
                }
                if(panel->flag & PNL_OVERLAP) {
-                       glColor3ub(240, 240, 240);
+                       BIF_ThemeColor(curarea, TH_TEXT_HI);
                        uiRoundRect(block->minx, block->miny, block->minx+PNL_HEADER, block->maxy+PNL_HEADER, 10);
                }
        
@@ -875,7 +873,7 @@ void ui_draw_panel(uiBlock *block)
                uiSetRoundBox(3);
 
                if(panel->control & UI_PNL_SOLID) {
-                       BIF_ThemeColor(curarea, TH_HEADER);
+                       BIF_ThemeColorShade(curarea, TH_HEADER, -30);
                        uiRoundBox(block->minx, block->maxy, block->maxx, block->maxy+PNL_HEADER, 10);
                        // blend now for panels in 3d window, test...
                        glBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA );
@@ -894,7 +892,7 @@ void ui_draw_panel(uiBlock *block)
                        glDisable(GL_BLEND);
                }
                else if(panel->control & UI_PNL_TRANSP) {
-                       glColor3ub(218, 218, 218);
+                       BIF_ThemeColorShade(curarea, TH_BACK, 32);
                        uiRoundRect(block->minx, block->miny, block->maxx, block->maxy+PNL_HEADER, 10);
                }
                
@@ -904,11 +902,11 @@ void ui_draw_panel(uiBlock *block)
                //  border
                uiSetRoundBox(3);
                if(panel->flag & PNL_SELECT) {
-                       glColor3ub(64, 64, 64);
+                       BIF_ThemeColorShade(curarea, TH_HEADER, -120);
                        uiRoundRect(block->minx, block->miny, block->maxx, block->maxy+PNL_HEADER, 10);
                }
                if(panel->flag & PNL_OVERLAP) {
-                       glColor3ub(240, 240, 240);
+                       BIF_ThemeColor(curarea, TH_TEXT_HI);
                        uiRoundRect(block->minx, block->miny, block->maxx, block->maxy+PNL_HEADER, 10);
                }
                
index 36172a09f5a4e0f1f2d06baf39dcf30285196223..4e420def8b2e1072da22de3b5a14ca9e3a7342b6 100644 (file)
@@ -358,14 +358,11 @@ char *BIF_ThemeGetColorPtr(bTheme *btheme, int spacetype, int colorid)
                        case SPACE_VIEW3D:
                                ts= &btheme->tv3d;
                                break;
-                       case SPACE_FILE:
-                               ts= &btheme->tfile;
-                               break;
                        case SPACE_IPO:
                                ts= &btheme->tipo;
                                break;
                        default:
-                               ts= &btheme->tbuts;
+                               ts= &btheme->tv3d;
                                break;
                        }
                        
@@ -447,6 +444,9 @@ void BIF_InitThemeColors(void)
        SETCOL(btheme->tv3d.header, 195, 195, 195, 255);
        SETCOL(btheme->tv3d.panel,      165, 165, 165, 100);
        
+       SETCOL(btheme->tv3d.shade1,  160, 160, 160, 100);
+       SETCOL(btheme->tv3d.shade2,  0x7f, 0x70, 0x70, 100);
+
        SETCOL(btheme->tv3d.grid,       0x60, 0x60, 0x60, 255);
        SETCOL(btheme->tv3d.wire,       0x0, 0x0, 0x0, 255);
        SETCOL(btheme->tv3d.select, 0xff, 0x88, 0xff, 255);
@@ -461,11 +461,40 @@ void BIF_InitThemeColors(void)
        SETCOL(btheme->tv3d.face_select, 200, 100, 200, 60);
 
        /* copy this to the others, to have something initialized */
-       
        btheme->tbuts= btheme->tv3d;
-       btheme->tfile= btheme->tv3d;
+
+       SETCOL(btheme->tbuts.back,      180, 180, 180, 255);
+       SETCOL(btheme->tbuts.header, 195, 195, 195, 255);
+       SETCOL(btheme->tbuts.panel,  255, 255, 255, 100);
+
        btheme->tipo= btheme->tv3d;
 
+       SETCOL(btheme->tipo.grid,       94, 94, 94, 255);
+       SETCOL(btheme->tipo.back,       120, 120, 120, 255);
+       SETCOL(btheme->tipo.header, 195, 195, 195, 255);
+       SETCOL(btheme->tipo.panel,  255, 255, 255, 100);
+       SETCOL(btheme->tipo.shade1,  140, 140, 140, 100);
+       SETCOL(btheme->tipo.shade2,  0x7f, 0x70, 0x70, 100);
+       SETCOL(btheme->tipo.vertex, 0xff, 0x70, 0xff, 255);
+       SETCOL(btheme->tipo.vertex_select, 0xff, 0xff, 0x70, 255);
+       SETCOL(btheme->tipo.hilite, 0x60, 0xc0, 0x40, 255); // green cfra line
+
+       btheme->tfile= btheme->tv3d;
+
+       btheme->tinfo= btheme->tv3d;
+       
+       btheme->tsnd= btheme->tv3d;
+       SETCOL(btheme->tsnd.grid,0x70, 0x70, 0x60, 255);
+       
+       btheme->tact= btheme->tv3d;
+       btheme->tnla= btheme->tv3d;
+       btheme->tseq= btheme->tv3d;
+       btheme->tima= btheme->tv3d;
+       btheme->timasel= btheme->tv3d;
+       btheme->text= btheme->tv3d;
+       btheme->toops= btheme->tv3d;
+
+
 }
 
 char *BIF_ThemeColorsPup(int spacetype)
@@ -483,9 +512,9 @@ char *BIF_ThemeColorsPup(int spacetype)
                sprintf(str, "Text Hilite %%x%d|", TH_TEXT_HI); strcat(cp, str);
                sprintf(str, "Header %%x%d|", TH_HEADER); strcat(cp, str);
                sprintf(str, "Panel %%x%d|", TH_PANEL); strcat(cp, str);
-               strcat(cp,"%l|");
                
                if(spacetype==SPACE_VIEW3D) {
+                       strcat(cp,"%l|");
                        sprintf(str, "Grid %%x%d|", TH_GRID); strcat(cp, str);
                        sprintf(str, "Wire %%x%d|", TH_WIRE); strcat(cp, str);
                        sprintf(str, "Object Selected %%x%d|", TH_SELECT); strcat(cp, str);
@@ -501,11 +530,14 @@ char *BIF_ThemeColorsPup(int spacetype)
                        // last item without '|'
                        sprintf(str, "Face Selected %%x%d", TH_FACE_SELECT); strcat(cp, str);
                }
-               else {
+               else if(spacetype==SPACE_IPO) {
+                       strcat(cp,"%l|");
                        sprintf(str, "Main Shade %%x%d|", TH_SHADE1); strcat(cp, str);
                        sprintf(str, "Alt Shade %%x%d|", TH_SHADE2); strcat(cp, str);
+                       sprintf(str, "Vertex %%x%d|", TH_VERTEX); strcat(cp, str);
+                       sprintf(str, "Vertex Selected %%x%d|", TH_VERTEX_SELECT); strcat(cp, str);
+                       sprintf(str, "Current frame %%x%d", TH_HILITE); strcat(cp, str);
                        // last item without '|'
-                       sprintf(str, "General Hilite %%x%d", TH_HILITE); strcat(cp, str);
                }
        }
        return cp;
index d5901227cd1db32fd5edd716cf0d26967ed36373..d5d1f19046a4f86a0db3bd47a0bbea1e754ef6a1 100644 (file)
@@ -1596,7 +1596,7 @@ void info_user_themebuts(uiBlock *block, short y1, short y2, short y3)
        uiDefBut(block, TEX, B_NAME_THEME, "",                  255,y3,200,20, btheme->name, 1.0, 30.0, 0, 0, "Rename theme");
 
        /* main choices pup */
-       uiDefButS(block, MENU, B_CHANGE_THEME, "UI and Buttons %x1|3D View %x2|Ipo Window %x3|Buttons Window %x4|File Select %x5",
+       uiDefButS(block, MENU, B_CHANGE_THEME, "UI and Buttons %x1|3D View %x2|Ipo Window %x3|Buttons Window %x4",
                                                                                                        255,y2,200,20, &curmain, 0, 0, 0, 0, "Specify theme for...");
        if(curmain==2) spacetype= SPACE_VIEW3D;
        if(curmain==3) spacetype= SPACE_IPO;