Re: [E-devel] E CVS: apps/e jeffdameth
On 01/06/2008 20:31, Enlightenment CVS wrote: Enlightenment CVS committal Author : jeffdameth Project : e17 Module : apps/e Dir : e17/apps/e/src/modules/pager Modified Files: e_mod_main.c Log Message: better naming for actions replace whitespaces with tabs I could be mistaken here but. I beleive tabs are less than desirable. In fact I am about to go through and replace all the vim cino directives in the code so that all tabs are replaced by spaces. (after getting comments from the ML) === RCS file: /cvs/e/e17/apps/e/src/modules/pager/e_mod_main.c,v retrieving revision 1.224 retrieving revision 1.225 diff -u -3 -r1.224 -r1.225 --- e_mod_main.c 7 Jan 2008 01:46:53 - 1.224 +++ e_mod_main.c 7 Jan 2008 02:31:52 - 1.225 @@ -701,7 +701,7 @@ pp-pager-popup = pp; pp-urgent = 0; - + e_zone_desk_count_get(zone, x, y); if (keyaction) @@ -735,11 +735,11 @@ ((zone-h - h) / 2), w, h); e_bindings_mouse_grab(E_BINDING_CONTEXT_POPUP, pp-popup-evas_win); e_bindings_wheel_grab(E_BINDING_CONTEXT_POPUP, pp-popup-evas_win); - + e_popup_show(pp-popup); - + pp-timer = NULL; - + return pp; } @@ -844,7 +844,7 @@ if (!pager_config) return; if (pager_config-config_dialog) return; /* FIXME: pass zone config item */ - _config_pager_module(NULL); + _config_pager_module(NULL); return pager_config-config_dialog; } @@ -926,9 +926,9 @@ pd = l-data; pw = _pager_desk_window_find(pd, ev-border); if (pw) _pager_window_move(pw); - } + } } - + return 1; } @@ -1099,7 +1099,7 @@ return 1; } -static void +static void _pager_window_desk_change(Pager *pager, E_Border *bd) { Evas_List *l; @@ -1224,14 +1224,14 @@ E_Event_Border_Desk_Set *ev; Evas_List *l; Pager *p; - + ev = event; for (l = pagers; l; l = l-next) { p = l-data; _pager_window_desk_change(p, ev-border); } - + return 1; } @@ -1544,7 +1544,7 @@ Pager *p; Pager_Desk *pd; Pager_Popup *pp; - + ev = event; for (l = pagers; l; l = l-next) { @@ -1562,7 +1562,7 @@ if (pager_config-popup !act_popup) { if (pp = _pager_popup_find(ev-desk-zone)) - { + { ecore_timer_del(pp-timer); } else @@ -1635,7 +1635,7 @@ { Evas_Event_Mouse_In *ev; Pager_Win *pw; - + ev = event_info; pw = data; /* FIXME: display window title in some tooltip thing */ @@ -1660,7 +1660,7 @@ ev = event_info; pw = data; - + if (!pw) return; if (pw-desk-pager-popup !act_popup) return; if (pw-border-lock_user_location) return; @@ -1689,13 +1689,13 @@ Evas_Event_Mouse_Up *ev; Pager_Win *pw; Pager *p; - + ev = event_info; pw = data; if (!pw) return; p = pw-desk-pager; - + if (pw-desk-pager-popup !act_popup) return; if (ev-button == pager_config-btn_desk) return; if ((ev-button == pager_config-btn_drag) || @@ -1725,7 +1725,7 @@ unsigned int resist = 0; Evas_Coord mx, my, vx, vy; Pager_Desk *pd; - + ev = event_info; pw = data; @@ -1769,7 +1769,7 @@ { evas_object_geometry_get(pw-o_window, x, y, w, h); evas_object_hide(pw-o_window); - + drag = e_drag_new(pw-desk-pager-zone-container, x, y, drag_types, 2, pw, -1, _pager_window_cb_drag_convert, @@ -1858,13 +1858,13 @@ } else y = 0; e_border_move(pw-border, x, y); - + if (!(pw-border-lock_user_stacking)) e_border_raise(pw-border); } if (pw pw-drag.from_pager) pw-drag.from_pager-dragging = 0; pw-drag.from_pager = NULL; - + if (act_popup) { e_grabinput_get(input_window, 0, input_window); @@ -1918,11 +1918,11 @@ p = data; /* FIXME this fixes a segv, but the case is not easy -* reproduceable. this makes no sense either since -* the same 'pager' is passed to e_drop_handler_add +* reproduceable. this makes no sense either since +* the same 'pager' is passed to e_drop_handler_add * and it works without this almost all the time. * so this must be an issue with e_dnd code... i guess */ - if (act_popup) p = act_popup-pager; + if (act_popup) p = act_popup-pager; _pager_update_drop_position(p, ev-x, ev-y); @@ -1942,7 +1942,7 @@ ev = event_info; p = data; - if (act_popup) p = act_popup-pager; + if (act_popup) p = act_popup-pager; _pager_update_drop_position(p, ev-x, ev-y); @@ -1962,7 +1962,7 @@
Re: [E-devel] E CVS: apps/e jeffdameth
On Jan 7, 2008 11:35 AM, Ravenlock [EMAIL PROTECTED] wrote: On 01/06/2008 20:31, Enlightenment CVS wrote: Enlightenment CVS committal Author : jeffdameth Project : e17 Module : apps/e Dir : e17/apps/e/src/modules/pager Modified Files: e_mod_main.c Log Message: better naming for actions replace whitespaces with tabs I could be mistaken here but. I beleive tabs are less than desirable. In fact I am about to go through and replace all the vim cino directives in the code so that all tabs are replaced by spaces. (after getting comments from the ML) raster's coding style (joe default?) is 1 tab to replace 8 spaces, weird I know... :-/ -- Gustavo Sverzut Barbieri -- Jabber: [EMAIL PROTECTED] MSN: [EMAIL PROTECTED] ICQ#: 17249123 Skype: gsbarbieri Mobile: +55 (81) 9927 0010 - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/ ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On 01/07/2008 07:48, Gustavo Sverzut Barbieri wrote: On Jan 7, 2008 11:35 AM, Ravenlock [EMAIL PROTECTED] wrote: On 01/06/2008 20:31, Enlightenment CVS wrote: Enlightenment CVS committal Author : jeffdameth Project : e17 Module : apps/e Dir : e17/apps/e/src/modules/pager Modified Files: e_mod_main.c Log Message: better naming for actions replace whitespaces with tabs I could be mistaken here but. I beleive tabs are less than desirable. In fact I am about to go through and replace all the vim cino directives in the code so that all tabs are replaced by spaces. (after getting comments from the ML) raster's coding style (joe default?) is 1 tab to replace 8 spaces, weird I know... :-/ I thought it was the other way around. It was my understanding that raster replaced the tabs with 8 spaces. I must be mistaken. Either way... the sources are a hodgepodge of formatting. I wonder what folks would think of a document formalizing the style of the sources. And possible a set of scripts to sweep through and correct them. Any thoughts? -- Regards, Ravenlock signature.asc Description: OpenPGP digital signature - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On Monday, 07 January 2008, at 09:21:25 (-0600), Ravenlock wrote: raster's coding style (joe default?) is 1 tab to replace 8 spaces, weird I know... :-/ I thought it was the other way around. It was my understanding that raster replaced the tabs with 8 spaces. I must be mistaken. No, Gustavo is. raster's style is contained in e17/libs/imlib2/.indent.pro: -i3 -nut -brs -bl -bad -nbap -sob -ncdb -di20 -nbc -lp -nce -npcs -sc -ncs -l80 Note the -nut which means use spaces, not tabs. Either way... the sources are a hodgepodge of formatting. I wonder what folks would think of a document formalizing the style of the sources. And possible a set of scripts to sweep through and correct them. Any thoughts? No script is needed. Just run indent on the sources with the options shown above. Michael -- Michael Jennings (a.k.a. KainX) http://www.kainx.org/ [EMAIL PROTECTED] Linux Server/Cluster Admin, LBL.gov Author, Eterm (www.eterm.org) --- Follow me; everything is alright. I'll be the one to tuck you in at night. And if you want to leave, I can guarantee you won't find nobody else like me. -- Uncle Kracker, Follow Me - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/ ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On 01/07/2008 09:26, Michael Jennings wrote: On Monday, 07 January 2008, at 09:21:25 (-0600), Ravenlock wrote: raster's coding style (joe default?) is 1 tab to replace 8 spaces, weird I know... :-/ I thought it was the other way around. It was my understanding that raster replaced the tabs with 8 spaces. I must be mistaken. No, Gustavo is. raster's style is contained in e17/libs/imlib2/.indent.pro: -i3 -nut -brs -bl -bad -nbap -sob -ncdb -di20 -nbc -lp -nce -npcs -sc -ncs -l80 Excellent. I had not seen this in cvs. This is exactly what is needed. Thanks. Note the -nut which means use spaces, not tabs. Either way... the sources are a hodgepodge of formatting. I wonder what folks would think of a document formalizing the style of the sources. And possible a set of scripts to sweep through and correct them. Any thoughts? No script is needed. Just run indent on the sources with the options shown above. Michael -- Regards, Ravenlock signature.asc Description: OpenPGP digital signature - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On 7-Jan-08, at 10:26 AM, Michael Jennings wrote: On Monday, 07 January 2008, at 09:21:25 (-0600), Ravenlock wrote: Either way... the sources are a hodgepodge of formatting. I wonder what folks would think of a document formalizing the style of the sources. And possible a set of scripts to sweep through and correct them. Any thoughts? No script is needed. Just run indent on the sources with the options shown above. Note that it is only Rasters code that is formatted this way. Don't run this against all the source in CVS as I know for a fact it's wrong for Efreet and Ewl. dan - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/ ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On 01/07/2008 09:52, dan sinclair wrote: On 7-Jan-08, at 10:26 AM, Michael Jennings wrote: On Monday, 07 January 2008, at 09:21:25 (-0600), Ravenlock wrote: Either way... the sources are a hodgepodge of formatting. I wonder what folks would think of a document formalizing the style of the sources. And possible a set of scripts to sweep through and correct them. Any thoughts? No script is needed. Just run indent on the sources with the options shown above. Note that it is only Rasters code that is formatted this way. Don't run this against all the source in CVS as I know for a fact it's wrong for Efreet and Ewl. I will definitely not go off and run indent on everyones code. Additionally, I will not go off and run it on *anyones* code until it has been discussed on the ML. I think it would be helpful across the board, for all devs involved if we had proper indent specifications so that all code could be kept consistent in this fashion. Meaning if each app/lib had its own indent spec, thats fine, as long as it exists and can be found and used by folks. This way you could happily write code in your own style, then indent it and ci. Just a thought. I will propose something along these lines in a separate thread as soon as I can, for comments. dan - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/ ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel -- Regards, Ravenlock signature.asc Description: OpenPGP digital signature - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On 01/07/2008 10:50, Michael Jennings wrote: On Monday, 07 January 2008, at 10:52:57 (-0500), dan sinclair wrote: Note that it is only Rasters code that is formatted this way. Don't run this against all the source in CVS as I know for a fact it's wrong for Efreet and Ewl. Each project is responsible for keeping a .indent.pro at the top level (see e_modules for an example). Any project not doing so is subject to the default style. This makes it easy for both project maintainers and the cleanup crew. I've run the .indent.pro you point out on several files in e/src/bin... and the difference is quite alarming! I'd say the cleanup crew has not been around in some time. Michael -- Regards, Ravenlock signature.asc Description: OpenPGP digital signature - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On Jan 7, 2008 1:26 PM, Michael Jennings [EMAIL PROTECTED] wrote: On Monday, 07 January 2008, at 09:21:25 (-0600), Ravenlock wrote: raster's coding style (joe default?) is 1 tab to replace 8 spaces, weird I know... :-/ I thought it was the other way around. It was my understanding that raster replaced the tabs with 8 spaces. I must be mistaken. No, Gustavo is. raster's style is contained in e17/libs/imlib2/.indent.pro: -i3 -nut -brs -bl -bad -nbap -sob -ncdb -di20 -nbc -lp -nce -npcs -sc -ncs -l80 Note the -nut which means use spaces, not tabs. Really? Every time raster touch code I see spaces replaced by tabs, I even had to change my .emacs to reflect this for files under ~/Development/cvs/e17 -- Gustavo Sverzut Barbieri -- Jabber: [EMAIL PROTECTED] MSN: [EMAIL PROTECTED] ICQ#: 17249123 Skype: gsbarbieri Mobile: +55 (81) 9927 0010 - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
Gustavo Sverzut Barbieri wrote: On Jan 7, 2008 1:26 PM, Michael Jennings [EMAIL PROTECTED] wrote: On Monday, 07 January 2008, at 09:21:25 (-0600), Ravenlock wrote: raster's coding style (joe default?) is 1 tab to replace 8 spaces, weird I know... :-/ I thought it was the other way around. It was my understanding that raster replaced the tabs with 8 spaces. I must be mistaken. No, Gustavo is. raster's style is contained in e17/libs/imlib2/.indent.pro: -i3 -nut -brs -bl -bad -nbap -sob -ncdb -di20 -nbc -lp -nce -npcs -sc -ncs -l80 Note the -nut which means use spaces, not tabs. Really? Every time raster touch code I see spaces replaced by tabs, I even had to change my .emacs to reflect this for files under ~/Development/cvs/e17 I put that file there at a point where I got annoyed with the formatting style mess in imlib2. The formatting style details, among other things tabs/spaces, were set up in an attempt to minimize the overall change caused by running indent on src/lib/*.c at that time. IIRC using spaces in stead of tabs resulted in slightly fewer changes. Actually, I think the original raster formatting style is closer to the one in e16/e/.indent.pro, which specifies to use tabs. I think it would be a good thing to specify a recommended/default indent profile, and require that apps/libs explicitly place a .indent.pro at top level if they want to deviate. /Kim - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Re: [E-devel] E CVS: apps/e jeffdameth
On Monday, 07 January 2008, at 19:58:38 (+0100), Kim Woelders wrote: I put that file there at a point where I got annoyed with the formatting style mess in imlib2. The formatting style details, among other things tabs/spaces, were set up in an attempt to minimize the overall change caused by running indent on src/lib/*.c at that time. IIRC using spaces in stead of tabs resulted in slightly fewer changes. Actually, I think the original raster formatting style is closer to the one in e16/e/.indent.pro, which specifies to use tabs. I think it would be a good thing to specify a recommended/default indent profile, and require that apps/libs explicitly place a .indent.pro at top level if they want to deviate. Here are the original indent profiles from back when we first started using indent: alias indent-mej=indent -bap -bbo -br -brs -ce -ci4 -cli2 -cs -di1 -hnl -i4 -l140 -lp -lps -nbc -npcs -nss -nsob -pmt -psl -ts 999 alias indent-raster=indent -i3 -bl -bad -nbap -sob -ncdb -di20 -nbc -lp -nce -npcs -sc -ncs -l80 alias indent-mandrake=indent -i3 -bl -bad -nbap -sob -ncdb -di20 -nbc -lp -nce -npcs -sc -ncs -l80 alias indent-gilbertt=indent -nbad -bap -nbc -bbo -bl -bli2 -bls -ncdb -nce -cp1 -cs -di2 -ndj -nfc1 -nfca -hnl -i2 -ip5 -lp -pcs -psl -nsc -nsob alias indent-ck=indent -i3 -bl -bad -nbap -sob -ncdb -di20 -nbc -lp -nce -npcs -sc -ncs -l80 At this point in time, I'm pretty sure we (or at least I) looked for a way to prevent the use of tabs, and there was no option for it at the time (at least that we found) in the version we were using. You'll notice the -ts 999 in mine -- that did essentially the same thing. This was back in 1999, so things have changed since then, obviously. Bottom line: Spaces make sure everyone sees the same indentation. Tabs do not. Since re-indenting code is very easy these days, using tabs as a way of defining spacing is no longer useful and actually does more harm than good. So use spaces, not tabs. If your version of indent still defaults to using tabs, add -nut. Michael -- Michael Jennings (a.k.a. KainX) http://www.kainx.org/ [EMAIL PROTECTED] Linux Server/Cluster Admin, LBL.gov Author, Eterm (www.eterm.org) --- And you women try to make us feel better about it. 'It's not the size of the ship that counts; it's the motion of the ocean.' Well, that may be true, but it takes an awfully long time to get to England in a rowboat. -- Jeff Foxworthy - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel