|
From: Daniel J S. <dan...@ie...> - 2006-04-10 08:44:56
|
Daniel J Sebald wrote: > Ethan A Merritt wrote: > >> On Saturday 08 April 2006 07:30 pm, Daniel Sebald wrote: >> >> >>> Anyway, I know that this is bloated. My philosophy to these patches >>> with conditional code has always been that if one turns off the >>> experimental feature it goes back *exactly* to the code before the >>> patch was applied. >> >> >> >> Right idea, but there is a better way to accomplish this. >> >> Step 1-5: > > > Got it. I can create a couple patches to reduce this the conditionals. I've created some updated patches, Ethan. Give them a try. Conditional code is greatly reduced with replacement by defines in header files when possible. After some extra variables to rid the -3/-2/-1 confusion, I moved this >>>+#ifdef FOO >>> if (plot_number < 0) return NULL; >>>+#endif to x11.trm and so that the gplt_x11.c code has no concern about sign. I think we learned from the palette code of a few weeks back that blocking things before going into the pipe is a good idea. We can hagle over what should be proper behavior if you think the code looks more organized. Dan |