56bb3dff4ba499246547040f35332f91bc2ee967
braney
  Sat Jun 30 08:14:48 2012 -0700
add some more info about the CDS start and end (#8249)
diff --git src/hg/hgGene/hgGene.c src/hg/hgGene/hgGene.c
index f8268e3..1d3e568 100644
--- src/hg/hgGene/hgGene.c
+++ src/hg/hgGene/hgGene.c
@@ -6,30 +6,31 @@
 #include "dystring.h"
 #include "jksql.h"
 #include "cheapcgi.h"
 #include "htmshell.h"
 #include "cart.h"
 #include "hui.h"
 #include "dbDb.h"
 #include "hdb.h"
 #include "web.h"
 #include "botDelay.h"
 #include "ra.h"
 #include "spDb.h"
 #include "genePred.h"
 #include "hgColors.h"
 #include "hgGene.h"
+#include "obscure.h"
 
 
 /* ---- Global variables. ---- */
 struct cart *cart;	/* This holds cgi and other variables between clicks. */
 struct hash *oldVars;	/* Old cart hash. */
 char *database;		/* Name of genome database - hg15, mm3, or the like. */
 char *genome;		/* Name of genome - mouse, human, etc. */
 char *curGeneId;	/* Current Gene Id. */
 char *curGeneName;		/* Biological name of gene. */
 char *curGeneChrom;	/* Chromosome current gene is on. */
 struct genePred *curGenePred;	/* Current gene prediction structure. */
 int curGeneStart,curGeneEnd;	/* Position in chromosome. */
 struct sqlConnection *spConn;	/* Connection to SwissProt database. */
 char *swissProtAcc;		/* SwissProt accession (may be NULL). */
 int  kgVersion = KG_UNKNOWN;	/* KG version */
@@ -239,52 +240,67 @@
     }
 return dyStringCannibalize(&description);
 }
 
 static void printDescription(char *id, struct sqlConnection *conn)
 /* Print out description of gene given ID. */
 {
 char *description = descriptionString(id, conn);
 int  i, exonCnt = 0, cdsExonCnt = 0;
 int  cdsStart, cdsEnd;
 
 hPrintf("%s", description);
 freez(&description);
 
 /* print genome position and size */
-hPrintf("<B>Strand:</B> %s\n", curGenePred->strand);
-hPrintf("&nbsp;&nbsp;<B>Genomic Size:</B> %d\n", curGeneEnd - curGeneStart);
+char asciiNumber[1024];
+hPrintf("<B>Transcription Chromosome:</B> %s\n", curGeneChrom);
+hPrintf("&nbsp;&nbsp;<B>Strand:</B> %s\n", curGenePred->strand);
+sprintLongWithCommas(asciiNumber, (long long)curGeneEnd - curGeneStart);
+hPrintf("&nbsp;&nbsp;<B>Size:</B> %s\n", asciiNumber);
+sprintLongWithCommas(asciiNumber, (long long) curGeneStart);
+hPrintf("&nbsp;&nbsp;<B>Start:</B> %s\n", asciiNumber);
+sprintLongWithCommas(asciiNumber, (long long)curGeneEnd);
+hPrintf("&nbsp;&nbsp;<B>End:</B> %s\n", asciiNumber);
 
 /* print exon count(s) */
 exonCnt = curGenePred->exonCount;
+hPrintf("&nbsp;&nbsp;<B>Exon Count:</B> %d\n", exonCnt);
+
 cdsStart= curGenePred->cdsStart;
 cdsEnd  = curGenePred->cdsEnd;
-hPrintf("&nbsp;&nbsp;<B>Exon Count:</B> %d\n", exonCnt);
 
 /* count CDS exons */
 if (cdsStart < cdsEnd)
     {
     for (i=0; i<exonCnt; i++)
 	{
 	if ( (cdsStart <= curGenePred->exonEnds[i]) &&
 	     (cdsEnd >= curGenePred->exonStarts[i]) )
 	     cdsExonCnt++;
 	}
-    }
 /* print CDS exon count only if it is different than exonCnt */
-hPrintf("&nbsp;&nbsp;");
-hPrintf("<B>Coding Exon Count:</B> %d\n", cdsExonCnt);
+    hPrintf("<BR>");
+    hPrintf("<B>Coding&nbsp;&nbsp;");
+    sprintLongWithCommas(asciiNumber, (long long)cdsEnd - cdsStart);
+    hPrintf("Size:</B> %s\n", asciiNumber);
+    sprintLongWithCommas(asciiNumber, (long long) cdsStart);
+    hPrintf("<B>Start:</B> %s\n", asciiNumber);
+    sprintLongWithCommas(asciiNumber, (long long)cdsEnd );
+    hPrintf("&nbsp;&nbsp;<B>End:</B> %s\n", asciiNumber);
+    hPrintf("<B>Exon Count:</B> %d\n", cdsExonCnt);
+    }
 fflush(stdout);
 }
 
 char *sectionSetting(struct section *section, char *name)
 /* Return section setting value if it exists. */
 {
 return hashFindVal(section->settings, name);
 }
 
 char *sectionRequiredSetting(struct section *section, char *name)
 /* Return section setting.  Squawk and die if it doesn't exist. */
 {
 char *res = sectionSetting(section, name);
 if (res == NULL)
     errAbort("Can't find required %s field in %s in settings.ra",