Hello

I am sending a very simple patch that enhance a autocomplete for
format and linestyle attributes

regards

Pavel Stehule
*** ./src/bin/psql/tab-complete.c.orig	2011-03-14 11:59:22.000000000 +0100
--- ./src/bin/psql/tab-complete.c	2011-03-14 16:23:41.596278154 +0100
***************
*** 2828,2833 ****
--- 2828,2851 ----
  
  		COMPLETE_WITH_LIST(my_list);
  	}
+ 	else if (strcmp(prev2_wd, "\\pset") == 0)
+ 	{
+ 		if (strcmp(prev_wd, "format") == 0)
+ 		{
+ 			static const char *const my_list[] =
+ 				{"unaligned", "aligned", "wrapped", "html", "latex", 
+ 					"troff-ms", NULL};
+ 
+ 			COMPLETE_WITH_LIST(my_list);
+ 		}
+ 		else if (strcmp(prev_wd, "linestyle") == 0)
+ 		{
+ 			static const char *const my_list[] =
+ 				{"ascii", "old-ascii", "unicode", NULL};
+ 
+ 			COMPLETE_WITH_LIST(my_list);
+ 		}
+ 	}
  	else if (strcmp(prev_wd, "\\set") == 0)
  	{
  		matches = complete_from_variables(text, "", "");
-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to