Enhancement - info missing color

- Fixed bug whereby the info report was not reporting fg and bg
  color attributes.
This commit is contained in:
Paul Beckingham 2009-05-13 23:59:22 -04:00
parent c7d0b1c21b
commit 1da111ad6e

View file

@ -485,10 +485,12 @@ std::string handleInfo (TDB& tdb, T& task, Config& conf)
table.addCell (row, 1, allTags); table.addCell (row, 1, allTags);
} }
// uuid
row = table.addRow (); row = table.addRow ();
table.addCell (row, 0, "UUID"); table.addCell (row, 0, "UUID");
table.addCell (row, 1, refTask.getUUID ()); table.addCell (row, 1, refTask.getUUID ());
// entry
row = table.addRow (); row = table.addRow ();
table.addCell (row, 0, "Entered"); table.addCell (row, 0, "Entered");
Date dt (::atoi (refTask.getAttribute ("entry").c_str ())); Date dt (::atoi (refTask.getAttribute ("entry").c_str ()));
@ -504,6 +506,24 @@ std::string handleInfo (TDB& tdb, T& task, Config& conf)
table.addCell (row, 1, entry + " (" + age + ")"); table.addCell (row, 1, entry + " (" + age + ")");
// fg
std::string color = refTask.getAttribute ("fg");
if (color != "")
{
row = table.addRow ();
table.addCell (row, 0, "Foreground color");
table.addCell (row, 1, color);
}
// bg
color = refTask.getAttribute ("bg");
if (color != "")
{
row = table.addRow ();
table.addCell (row, 0, "Background color");
table.addCell (row, 1, color);
}
out << optionalBlankLine (conf) out << optionalBlankLine (conf)
<< table.render () << table.render ()
<< std::endl; << std::endl;