Fossil

Check-in [a5576e2d]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:made default css handled by loop instead of explizit calls, ..
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | wolfgangFormat2CSS
Files: files | file ages | folders
SHA1:a5576e2d51fc5c843b36e2cf3223de0591ee9d81
User & Date: wolfgang 2010-09-08 21:15:53
Context
2010-09-09
20:04
merged trunk to branch check-in: ef6979ea user: wolfgang tags: wolfgangFormat2CSS
2010-09-08
21:15
made default css handled by loop instead of explizit calls, .. check-in: a5576e2d user: wolfgang tags: wolfgangFormat2CSS
20:25
css for hyperlinks disabled check-in: 0e394b8f user: wolfgang tags: wolfgangFormat2CSS
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/setup.c.

906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
  @ CSS in order to pull in the modified CSS file.</p>
  @ <hr>
  @ The default CSS is shown below for reference.  Other examples
  @ of CSS files can be seen on the <a href="setup_skin">skins page</a>.
  @ See also the <a href="setup_header">header</a> and
  @ <a href="setup_footer">footer</a> editing screens.
  @ <blockquote><pre>
  @ %h(zDefaultCSS)
  @ %h(zTableLabelValueCSS)
  @ %h(zDivSidebox)
  @ %h(zDivSideboxTitle)
  @ %h(zDivSideboxDescribed)
  @ %h(zSpanDisabled)
  @ </pre></blockquote>
  style_footer();
  db_end_transaction(0);
}

/*
** WEBPAGE: setup_header
*/







|
<
<
<
<
<
<







906
907
908
909
910
911
912
913






914
915
916
917
918
919
920
  @ CSS in order to pull in the modified CSS file.</p>
  @ <hr>
  @ The default CSS is shown below for reference.  Other examples
  @ of CSS files can be seen on the <a href="setup_skin">skins page</a>.
  @ See also the <a href="setup_header">header</a> and
  @ <a href="setup_footer">footer</a> editing screens.
  @ <blockquote><pre>
  cgi_append_default_css();






  style_footer();
  db_end_transaction(0);
}

/*
** WEBPAGE: setup_header
*/

Changes to src/style.c.

380
381
382
383
384
385
386

387
388
389
390
391
392
393
394
395

396
397
398
399
400
401
402

403
404
405
406
407
408
409

410
411
412
413
414
415

416





































417
418
419
420
421
422
423

424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
const char zTableLabelValueCSS[] = 
@ /* The label/value pairs on (for example) the ci page */
@ table.label-value th {
@   vertical-align: top;
@   text-align: right;
@   padding: 0.2ex 2ex;
@ }

;
const char zDivSidebox[] =
@ /* The nomenclature sidebox for branches,.. */
@ div.sidebox {
@   float: right;
@   border-width: medium;
@   border-style: double;
@   margin: 10;
@ }

;
const char zDivSideboxTitle[] =
@ /* The nomenclature title in sideboxes for branches,.. */
@ div.sideboxTitle {
@   display: inline;
@   font-weight: bold;
@ }

;
const char zDivSideboxDescribed[] =
@ /* The defined element in sideboxes for branches,.. */
@ div.sideboxDescribed {
@   display: inline;
@   font-weight: bold;
@ }

;
const char zSpanDisabled[] =
@ /* The defined element in sideboxes for branches,.. */
@ span.disabled {
@   color: red;
@ }

;






































/*
** WEBPAGE: style.css
*/
void page_style_css(void){
  const char *zCSS    = 0;
  const char *zCSSdef = 0;


  cgi_set_content_type("text/css");
  zCSS = db_get("css",(char*)zDefaultCSS);
  /* append user defined css */
  cgi_append_content(zCSS, -1);
  /* add special missing definitions */
  if (!strstr("table.label-value",zCSS))       cgi_append_content(zTableLabelValueCSS, -1);
  if (!strstr("div.sidebox",zCSS))             cgi_append_content(zDivSidebox, -1);
  if (!strstr("div.sideboxTitle",zCSS))        cgi_append_content(zDivSideboxTitle, -1);
  if (!strstr("div.sideboxDescribed",zCSS))    cgi_append_content(zDivSideboxDescribed, -1);
  if (!strstr("span.disabled",zCSS))           cgi_append_content(zSpanDisabled, -1);
  g.isConst = 1;
}

/*
** WEBPAGE: test_env
*/
void page_test_env(void){







>









>







>







>






>

>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







>






|
|
|
<
<







380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475


476
477
478
479
480
481
482
const char zTableLabelValueCSS[] = 
@ /* The label/value pairs on (for example) the ci page */
@ table.label-value th {
@   vertical-align: top;
@   text-align: right;
@   padding: 0.2ex 2ex;
@ }
@
;
const char zDivSidebox[] =
@ /* The nomenclature sidebox for branches,.. */
@ div.sidebox {
@   float: right;
@   border-width: medium;
@   border-style: double;
@   margin: 10;
@ }
@
;
const char zDivSideboxTitle[] =
@ /* The nomenclature title in sideboxes for branches,.. */
@ div.sideboxTitle {
@   display: inline;
@   font-weight: bold;
@ }
@
;
const char zDivSideboxDescribed[] =
@ /* The defined element in sideboxes for branches,.. */
@ div.sideboxDescribed {
@   display: inline;
@   font-weight: bold;
@ }
@
;
const char zSpanDisabled[] =
@ /* The defined element in sideboxes for branches,.. */
@ span.disabled {
@   color: red;
@ }
@
;
const char zSpanTimelineSuppressed[] =
@ /* The suppressed duplicates lines in timeline, .. */
@ span.timelineDisabled {
@   font-style: italic;
@   font-size: small;
@ }
@
;
typedef enum cssDefaultItems {
  cssOthers = 0,
  tableLabelValue,
  divSidebox,
  divSideboxTitle,
  divSideboxDescribed,
  spanDisabled,
  spanTimelineSuppressed,
  cssDefaultCount
};
const struct strctCssDefaults {
  char const * const name;
  char const * const value;
} cssDefaultList[cssDefaultCount] = {
  { "",                      zDefaultCSS             },
  { "table.label-value",     zTableLabelValueCSS     },
  { "div.sidebox",           zDivSidebox             },
  { "div.sideboxTitle",      zDivSideboxTitle        },
  { "div.sideboxDescribed",  zDivSideboxDescribed    },
  { "span.disabled",         zSpanDisabled           },
  { "span.timelineDisabled", zSpanTimelineSuppressed }
};

void cgi_append_default_css(void) {
  enum cssDefaultItems i;

  for (i=cssOthers;i<cssDefaultCount;i++)
    cgi_printf(cssDefaultList[i].value);
}

/*
** WEBPAGE: style.css
*/
void page_style_css(void){
  const char *zCSS    = 0;
  const char *zCSSdef = 0;
  enum cssDefaultItems i;

  cgi_set_content_type("text/css");
  zCSS = db_get("css",(char*)zDefaultCSS);
  /* append user defined css */
  cgi_append_content(zCSS, -1);
  /* add special missing definitions */
  for (i=cssOthers+1;i<cssDefaultCount;i++)
    if (!strstr(zCSS,cssDefaultList[i].name))
      cgi_append_content(cssDefaultList[i].value, -1);


  g.isConst = 1;
}

/*
** WEBPAGE: test_env
*/
void page_test_env(void){

Changes to src/timeline.c.

217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
          commentColumn = 10;
        }
      }
    }
    prevTagid = tagid;
    if( suppressCnt ){
      @ <tr><td><td><td>
      @ <small><i>... %d(suppressCnt) similar
      @ event%s(suppressCnt>1?"s":"") omitted.</i></small></tr>
      suppressCnt = 0;
    }
    if( strcmp(zType,"div")==0 ){
      @ <tr><td colspan=3><hr></td></tr>
      continue;
    }
    if( memcmp(zDate, zPrevDate, 10) ){







|
|







217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
          commentColumn = 10;
        }
      }
    }
    prevTagid = tagid;
    if( suppressCnt ){
      @ <tr><td><td><td>
      @ <span class="timelineDisabled">... %d(suppressCnt) similar
      @ event%s(suppressCnt>1?"s":"") omitted.</span></tr>
      suppressCnt = 0;
    }
    if( strcmp(zType,"div")==0 ){
      @ <tr><td colspan=3><hr></td></tr>
      continue;
    }
    if( memcmp(zDate, zPrevDate, 10) ){