Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Restore the blue color for changed text in side-by-side diffs. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | diff-color-enhancements |
| Files: | files | file ages | folders |
| SHA3-256: |
00b5e02ab2fdc4c13cbe0fa075fdf655 |
| User & Date: | drh 2021-09-03 12:33:13.414 |
Context
|
2021-09-03
| ||
| 13:39 | First attempt at documenting the new diff web layout. ... (check-in: 07d28ec886 user: drh tags: diff-color-enhancements) | |
| 12:33 | Restore the blue color for changed text in side-by-side diffs. ... (check-in: 00b5e02ab2 user: drh tags: diff-color-enhancements) | |
| 12:23 | Merge recent trunk enhancements into the diff-color-enhancement branch. ... (check-in: 17dde4c75b user: drh tags: diff-color-enhancements) | |
Changes
Changes to src/default.css.
| ︙ | ︙ | |||
571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 |
text-decoration: none;
}
td.difftxt del > del {
background-color: #ffc0c0;
text-decoration: none;
font-weight: bold;
}
td.difftxt ins {
background-color: #dafbe1;
text-decoration: none;
}
td.difftxt ins > ins {
background-color: #a0e4b2;
text-decoration: none;
font-weight: bold;
}
span.modpending {
color: #b03800;
font-style: italic;
}
| > > > > > > > > > > | 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 |
text-decoration: none;
}
td.difftxt del > del {
background-color: #ffc0c0;
text-decoration: none;
font-weight: bold;
}
td.difftxt del > del.edit {
background-color: #c0c0ff;
text-decoration: none;
font-weight: bold;
}
td.difftxt ins {
background-color: #dafbe1;
text-decoration: none;
}
td.difftxt ins > ins {
background-color: #a0e4b2;
text-decoration: none;
font-weight: bold;
}
td.difftxt ins > ins.edit {
background-color: #c0c0ff;
text-decoration: none;
font-weight: bold;
}
span.modpending {
color: #b03800;
font-style: italic;
}
|
| ︙ | ︙ |
Changes to src/diff.c.
| ︙ | ︙ | |||
1591 1592 1593 1594 1595 1596 1597 |
blob_appendf(p->pOut,"%d\n", p->lnLeft);
for(i=x=0; i<span.n; i++){
int ofst = span.a[i].iStart1;
int len = span.a[i].iLen1;
if( len ){
htmlize_to_blob(&p->aCol[0], pX->z+x, ofst - x);
x = ofst;
| > > > | > > > > | > | 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 |
blob_appendf(p->pOut,"%d\n", p->lnLeft);
for(i=x=0; i<span.n; i++){
int ofst = span.a[i].iStart1;
int len = span.a[i].iLen1;
if( len ){
htmlize_to_blob(&p->aCol[0], pX->z+x, ofst - x);
x = ofst;
if( span.a[i].iLen2 ){
blob_append(&p->aCol[0], "<del class='edit'>", -1);
}else{
blob_append(&p->aCol[0], "<del>", 5);
}
htmlize_to_blob(&p->aCol[0], pX->z+x, len);
x += len;
blob_append(&p->aCol[0], "</del>", 6);
}
}
htmlize_to_blob(&p->aCol[0], pX->z+x, pX->n - x);
blob_append_char(&p->aCol[0], '\n');
blob_append(&p->aCol[1], "|\n", 2);
blob_appendf(&p->aCol[2],"%d\n", p->lnRight);
for(i=x=0; i<span.n; i++){
int ofst = span.a[i].iStart2;
int len = span.a[i].iLen2;
if( len ){
htmlize_to_blob(&p->aCol[3], pY->z+x, ofst - x);
x = ofst;
if( span.a[i].iLen1 ){
blob_append(&p->aCol[3], "<ins class='edit'>", -1);
}else{
blob_append(&p->aCol[3], "<ins>", 5);
}
htmlize_to_blob(&p->aCol[3], pY->z+x, len);
x += len;
blob_append(&p->aCol[3], "</ins>", 6);
}
}
htmlize_to_blob(&p->aCol[3], pY->z+x, pY->n - x);
blob_append_char(&p->aCol[3], '\n');
|
| ︙ | ︙ |