Merge branch 'TheMorc-pixelmodifications' into master

This commit is contained in:
Morgan Aldridge 2021-03-17 15:16:55 -04:00
commit c4fc6df49c
5 changed files with 27 additions and 39 deletions

View File

@ -204,7 +204,7 @@ void create_titlebar( MlvwmWindow *tmp_win )
if( tmp_win->flags&CLOSER ){
attributes.cursor = Scr.MlvwmCursors[DESTROY];
tmp_win->close_b = XCreateWindow( dpy, tmp_win->title_w,
Scr.flags&SYSTEM8?4:BOXSIZE+1,
Scr.flags&SYSTEM8?2:BOXSIZE+1,
(TITLE_HEIGHT-BOXSIZE)/2,
BOXSIZE, BOXSIZE, 0,
CopyFromParent, InputOutput,

View File

@ -55,13 +55,13 @@ void DrawShadowBox( int x, int y, int w, int h, Window win, int d, GC hilight, G
h--;
for( lp=0; lp<d; lp++ ){
if( mode&SHADOW_BOTTOM )
XDrawLine( dpy, win, shadow, x+lp, y+h-lp, x+w-lp, y+h-lp );
XDrawLine( dpy, win, shadow, x+lp+1, y+h-lp, x+w-lp, y+h-lp );
if( mode&SHADOW_LEFT )
XDrawLine( dpy, win, hilight, x+lp, y+lp, x+lp, y+h-lp );
XDrawLine( dpy, win, hilight, x+lp, y+lp, x+lp, y+h-lp-1 );
if( mode&SHADOW_TOP )
XDrawLine( dpy, win, hilight, x+lp, y+lp, x+w-lp, y+lp );
XDrawLine( dpy, win, hilight, x+lp, y+lp, x+w-lp-1, y+lp );
if( mode&SHADOW_RIGHT )
XDrawLine( dpy, win, shadow, x+w-lp, y+lp, x+w-lp, y+h-lp );
XDrawLine( dpy, win, shadow, x+w-lp, y+lp+1, x+w-lp, y+h-lp-1 );
}
}
@ -129,7 +129,7 @@ void SetUpFrame( MlvwmWindow *t, int x, int y, int w, int h, Bool sendEvent )
if( t->flags&MINMAXR ){
if( Scr.flags&SYSTEM8 )
XMoveWindow(dpy, t->minmax_b,
w-BOXSIZE-9-(t->flags&SHADER?BOXSIZE+4:0),
w-BOXSIZE-7-(t->flags&SHADER?BOXSIZE+4:0),
(TITLE_HEIGHT-BOXSIZE)/2);
else
XMoveWindow(dpy, t->minmax_b,
@ -137,7 +137,7 @@ void SetUpFrame( MlvwmWindow *t, int x, int y, int w, int h, Bool sendEvent )
(TITLE_HEIGHT-BOXSIZE)/2);
}
if( t->flags&SHADER )
XMoveWindow(dpy, t->shade_b, w-BOXSIZE-9,
XMoveWindow(dpy, t->shade_b, w-BOXSIZE-8,
(TITLE_HEIGHT-BOXSIZE)/2);
if( !(t->flags&SHADE) ){
if( t->flags & ( TITLE | SBARV | SBARH | RESIZER ) ){
@ -334,7 +334,7 @@ void DrawCloseBox( MlvwmWindow *t, Bool on )
if( Scr.flags&SYSTEM8 ){
XFillRectangle( dpy, t->title_w, Scr.Gray4GC,
4, (TITLE_HEIGHT-BOXSIZE)/2-2,
BOXSIZE+7, BOXSIZE+2 );
BOXSIZE+2, BOXSIZE+2 );
FillGradation( t->close_b );
}
else{
@ -376,13 +376,13 @@ void DrawMinMax( MlvwmWindow *t, Bool on )
if( on ){
if( Scr.flags&SYSTEM8 ){
XFillRectangle( dpy, t->title_w, Scr.Gray4GC,
t->frame_w-BOXSIZE-15-
t->frame_w-BOXSIZE-9-
(t->flags&SHADER?BOXSIZE+6:0),
(TITLE_HEIGHT-BOXSIZE)/2-1,
BOXSIZE+8, BOXSIZE+2 );
FillGradation( t->minmax_b );
XDrawRectangle( dpy, t->minmax_b, Scr.BlackGC,
1, 1, BOXSIZE-6, BOXSIZE-6 );
1, 1, BOXSIZE-7, BOXSIZE-7 );
}
else{
XFillRectangle( dpy, t->title_w, Scr.Gray4GC,
@ -488,30 +488,18 @@ void SetTitleBar( MlvwmWindow *t, Bool on_off )
while( w+20>drawable && titlelength>0 );
if( on_off ){
for( lp=4; lp<14; lp+=3 ){
for( lp=4; lp<16; lp+=2 ){
if( Scr.d_depth>1 ){
if( Scr.flags&SYSTEM8 )
DrawShadowBox( 4, lp-2, t->frame_w-15, 2, t->title_w, 1,
DrawShadowBox( 4, lp-1, t->frame_w-14, 2, t->title_w, 1,
Scr.WhiteGC, Scr.Gray1GC, SHADOW_ALL );
else
DrawShadowBox( 4, lp-1, t->frame_w-11, 2, t->title_w, 1,
Scr.Gray1GC, Scr.WhiteGC, SHADOW_ALL );
XDrawLine( dpy, t->title_w, Scr.Gray1GC, 0, lp, t->frame_w, lp );
}
else
XDrawLine( dpy, t->title_w, Scr.BlackGC,
4, lp-1, t->frame_w-7, lp-1 );
XDrawLine( dpy, t->title_w, Scr.BlackGC, 0, lp, t->frame_w, lp );
}
if( Scr.d_depth>1 ){
if( Scr.flags&SYSTEM8 )
DrawShadowBox( 4, 14, t->frame_w-15, 2, t->title_w, 1,
Scr.WhiteGC, Scr.Gray1GC, SHADOW_ALL );
else
XDrawLine( dpy, t->title_w, Scr.Gray1GC,
4, 15, t->frame_w-9, 15 );
}
else
XDrawLine( dpy, t->title_w, Scr.BlackGC,
4, 15, t->frame_w-7, 15 );
if( Scr.flags&SYSTEM8 ){
DrawShadowBox( 0, 0, t->frame_w-2, TITLE_HEIGHT, t->title_w,
1, Scr.WhiteGC, Scr.Gray2GC, SHADOW_TOP );
@ -523,7 +511,7 @@ void SetTitleBar( MlvwmWindow *t, Bool on_off )
DrawShadowBox( 0, 0, t->frame_w-2, TITLE_HEIGHT, t->title_w,
1, Scr.WhiteGC, Scr.Gray2GC, SHADOW_ALL );
XFillRectangle( dpy, t->title_w, Scr.Gray4GC,
(t->frame_w-w)/2-10, 1, w+20, TITLE_HEIGHT-2 );
(t->frame_w-w)/2-5, 1, w+10, TITLE_HEIGHT-2 );
dispgc = Scr.BlackGC;
}
else{

View File

@ -969,7 +969,7 @@ void MinMaxWindow( MlvwmWindow *mw, XEvent *evp )
DisplayPush( mw->minmax_b );
XDrawRectangle( dpy, mw->minmax_b, Scr.BlackGC,
1, 1, BOXSIZE-6, BOXSIZE-6 );
1, 1, BOXSIZE-7, BOXSIZE-7 );
while( !isEnd ){
XMaskEvent( dpy,
ButtonReleaseMask|EnterWindowMask|LeaveWindowMask, &ev );

View File

@ -12,7 +12,7 @@
#include <X11/Xutil.h>
#include <X11/xpm.h>
#define MENUB_H 25
#define MENUB_H 20
/* Definitions of Menu Item */
#define STRGRAY 1 /* Draw String Black or Gray? */

View File

@ -178,9 +178,9 @@ extern Atom _XA_WM_DESKTOP;
extern void Done( int, char * );
#ifdef USE_LOCALE
#define DEFAULTFS "-adobe-*-*-r-*-*-14-*-*-*-p-*-*-*,\
-*-*-*-r-*-*-14-*-*-*-*-*-*-*"
#define DEFAULTFS "-adobe-*-*-r-*-*-12-*-*-*-p-*-*-*,\
-*-*-*-r-*-*-12-*-*-*-*-*-*-*"
#else
#define DEFAULTFONT "-adobe-*-*-r-*-*-14-*-*-*-p-*-*-*"
#define DEFAULTFONT "-adobe-*-*-r-*-*-12-*-*-*-p-*-*-*"
#endif
#endif