Fossil

Check-in [5bba36b2bc]
Login

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

Overview
Comment:3 layouts in timeline moved to css
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | stv-skinning
Files: files | file ages | folders
SHA1: 5bba36b2bc2fb42bbf927495b91531eff1fe98b8
User & Date: Ratte 2010-09-05 09:58:55.000
Context
2010-09-05
10:59
sidebox via css ... (check-in: ff3b6b323b user: Ratte tags: stv-skinning)
09:58
3 layouts in timeline moved to css ... (check-in: 5bba36b2bc user: Ratte tags: stv-skinning)
07:16
comment in default style ... (check-in: b96d3e5c9f user: Ratte tags: stv-skinning)
Changes
Unified Diff Ignore Whitespace Patch
Changes to src/setup.c.
911
912
913
914
915
916
917

918
919
920
921
922
923
924
  @ <a href="setup_footer">footer</a> editing screens.
  @ <blockquote><pre>
  @ %h(zDefaultCSS)
  @ /* internal page layout */
  @ %h(zTdTimelineTimeStampCell)
  @ %h(zTdTimelineOmitted)
  @ %h(zTdTimelineComment)

  @ </pre></blockquote>
  style_footer();
  db_end_transaction(0);
}

/*
** WEBPAGE: setup_header







>







911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
  @ <a href="setup_footer">footer</a> editing screens.
  @ <blockquote><pre>
  @ %h(zDefaultCSS)
  @ /* internal page layout */
  @ %h(zTdTimelineTimeStampCell)
  @ %h(zTdTimelineOmitted)
  @ %h(zTdTimelineComment)
  @ %h(zTdTimelineLeafDsp)
  @ </pre></blockquote>
  style_footer();
  db_end_transaction(0);
}

/*
** WEBPAGE: setup_header
Changes to src/style.c.
335
336
337
338
339
340
341

342
343
344
345
346
347
348
@   margin-bottom: 0px;
@   margin-top: 1em;
@   padding: 1px 1px 1px 1px;
@   font-size: 1.2em;
@   font-weight: bold;
@   background-color: #558195;
@   color: white;

@ }
@
@ /* The "Date" that occurs on the left hand side of timelines */
@ div.divider {
@   background: #a1c4d4;
@   border: 2px #558195 solid;
@   font-size: 1em; font-weight: normal;







>







335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
@   margin-bottom: 0px;
@   margin-top: 1em;
@   padding: 1px 1px 1px 1px;
@   font-size: 1.2em;
@   font-weight: bold;
@   background-color: #558195;
@   color: white;
@   white-space: nowrap;
@ }
@
@ /* The "Date" that occurs on the left hand side of timelines */
@ div.divider {
@   background: #a1c4d4;
@   border: 2px #558195 solid;
@   font-size: 1em; font-weight: normal;
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
const char zTdTimelineComment[] =
@ /* The comment cell in timeline tables */
@ td.timelineComment {
@   valign: top;
@   text-align: left;
@ }
;







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

  cgi_set_content_type("text/css");
  zCSS = db_get("css",(char*)zDefaultCSS);
  cgi_append_content(zCSS, -1);
  cgi_append_content("\n", -1);
  /* append internal classes, if not already in style sheet */
  if (!strstr(zCSS,"timelineTimeStampCell"))
    cgi_append_content(zTdTimelineTimeStampCell,-1);
  if (!strstr(zCSS,"timelineOmitted"))
    cgi_append_content(zTdTimelineOmitted,-1);
  if (!strstr(zCSS,"timelineComment"))
    cgi_append_content(zTdTimelineComment,-1);


  g.isConst = 1;
}

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







>
>
>
>
>
>
>


















>
>







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
const char zTdTimelineComment[] =
@ /* The comment cell in timeline tables */
@ td.timelineComment {
@   valign: top;
@   text-align: left;
@ }
;
const char zTdTimelineLeafDsp[] =
@ /* The leaf description in timeline tables */
@ div.timelineLeafDsp {
@   font-weight: bold;
@   display: inline;
@ }
;
 
/*
** WEBPAGE: style.css
*/
void page_style_css(void){
  char *zCSS = 0;

  cgi_set_content_type("text/css");
  zCSS = db_get("css",(char*)zDefaultCSS);
  cgi_append_content(zCSS, -1);
  cgi_append_content("\n", -1);
  /* append internal classes, if not already in style sheet */
  if (!strstr(zCSS,"timelineTimeStampCell"))
    cgi_append_content(zTdTimelineTimeStampCell,-1);
  if (!strstr(zCSS,"timelineOmitted"))
    cgi_append_content(zTdTimelineOmitted,-1);
  if (!strstr(zCSS,"timelineComment"))
    cgi_append_content(zTdTimelineComment,-1);
  if (!strstr(zCSS,"timelineLeafDsp"))
    cgi_append_content(zTdTimelineLeafDsp,-1);
  g.isConst = 1;
}

/*
** WEBPAGE: test_env
*/
void page_test_env(void){
Changes to src/timeline.c.
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
    if( strcmp(zType,"div")==0 ){
      @ <tr><td colspan=3><hr></td></tr>
      continue;
    }
    if( memcmp(zDate, zPrevDate, 10) ){
      sprintf(zPrevDate, "%.10s", zDate);
      @ <tr><td>
      @   <div class="divider"><nobr>%s(zPrevDate)</nobr></div>
      @ </td></tr>
    }
    memcpy(zTime, &zDate[11], 5);
    zTime[5] = 0;
    @ <tr>
    @ <td class="timelineTimeStampCell">%s(zTime)</td>
    @ <td width="20" align="left" valign="top">







|







228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
    if( strcmp(zType,"div")==0 ){
      @ <tr><td colspan=3><hr></td></tr>
      continue;
    }
    if( memcmp(zDate, zPrevDate, 10) ){
      sprintf(zPrevDate, "%.10s", zDate);
      @ <tr><td>
      @   <div class="divider">%s(zPrevDate)</div>
      @ </td></tr>
    }
    memcpy(zTime, &zDate[11], 5);
    zTime[5] = 0;
    @ <tr>
    @ <td class="timelineTimeStampCell">%s(zTime)</td>
    @ <td width="20" align="left" valign="top">
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
    }
    if( zType[0]=='c' ){
      hyperlink_to_uuid(zUuid);
      if( isLeaf ){
        if( db_exists("SELECT 1 FROM tagxref"
                      " WHERE rid=%d AND tagid=%d AND tagtype>0",
                      rid, TAG_CLOSED) ){
          @ <b>Closed-Leaf:</b>
        }else{
          @ <b>Leaf:</b>
        }
      }
    }else if( (tmFlags & TIMELINE_ARTID)!=0 ){
      hyperlink_to_uuid(zUuid);
    }
    db_column_blob(pQuery, commentColumn, &comment);
    if( mxWikiLen>0 && blob_size(&comment)>mxWikiLen ){







|

|







276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
    }
    if( zType[0]=='c' ){
      hyperlink_to_uuid(zUuid);
      if( isLeaf ){
        if( db_exists("SELECT 1 FROM tagxref"
                      " WHERE rid=%d AND tagid=%d AND tagtype>0",
                      rid, TAG_CLOSED) ){
          @ <div class="timelineLeafDsp">Closed-Leaf:</div>
        }else{
          @ <div class="timelineLeafDsp">Leaf:</div>
        }
      }
    }else if( (tmFlags & TIMELINE_ARTID)!=0 ){
      hyperlink_to_uuid(zUuid);
    }
    db_column_blob(pQuery, commentColumn, &comment);
    if( mxWikiLen>0 && blob_size(&comment)>mxWikiLen ){