clbGraphMetrics_SelectedIndexChanged
(
object sender,
EventArgs e
)
{
AssertValid();
GraphMetricInformation oSelectedGraphMetricInformation;
if ( TryGetSelectedGraphMetricInformation(
out oSelectedGraphMetricInformation) )
{
// Insert the description, which is in HTML format, into a web
// page, then insert the web page into the wbDescription
// WebBrowser.
wbDescription.DocumentText = String.Format(
@"<html>
<head>
<style>
BODY
{{
border: 1px solid black;
}}
BODY, TABLE
{{
font-family: arial;
font-size: 9.0pt;
}}
TABLE
{{
border: 1px solid black;
border-collapse: collapse;
}}
TD, TH
{{
border: 1px solid black;
padding: 0.3em;
vertical-align: top;
}}
.divCaption
{{
border: 1px solid gray;
padding: 0.1em;
color: HighlightText;
background: Highlight;
}}
.divQuote, .divUrl
{{
margin-left: 2em;
}}
.spnOptions
{{
font-weight: bold;
}}
</style>
</head>
<body>
<div class=""divCaption"">{0}</div>
{1}
</body>
</html>"
,
oSelectedGraphMetricInformation.Name,
oSelectedGraphMetricInformation.DescriptionAsHtml
);
btnOptions.Enabled =
oSelectedGraphMetricInformation.HasUserSettings;
}
}