public void ThemeChanged(UITableViewCell cell)
{
_Cell = cell;
if (_Cell == null)
{
return;
}
if (_Cell.TextLabel != null)
{
if (TextFont != null)
{
_Cell.TextLabel.Font = TextFont;
}
_Cell.TextLabel.TextAlignment = TextAlignment;
_Cell.TextLabel.TextColor = TextColor ?? _Cell.TextLabel.TextColor;
if (TextShadowColor != null)
{
_Cell.TextLabel.ShadowColor = TextShadowColor;
}
if (TextShadowOffset != SizeF.Empty)
{
_Cell.TextLabel.ShadowOffset = TextShadowOffset;
}
if (TextHighlightColor != null)
{
_Cell.TextLabel.HighlightedTextColor = TextHighlightColor;
}
}
if (_Cell.DetailTextLabel != null)
{
if (DetailTextFont != null)
{
_Cell.DetailTextLabel.Font = DetailTextFont;
}
_Cell.DetailTextLabel.TextAlignment = DetailTextAlignment;
_Cell.DetailTextLabel.TextColor = DetailTextColor ?? _Cell.DetailTextLabel.TextColor;
if (DetailTextShadowColor != null)
{
_Cell.DetailTextLabel.ShadowColor = DetailTextShadowColor;
}
if (DetailTextShadowOffset != SizeF.Empty)
{
_Cell.DetailTextLabel.ShadowOffset = DetailTextShadowOffset;
}
if (DetailTextHighlightColor != null)
{
_Cell.DetailTextLabel.HighlightedTextColor = DetailTextHighlightColor;
}
}
if (CellBackgroundColor != null)
{
_Cell.BackgroundColor = CellBackgroundColor;
}
else if (CellBackgroundImage != null)
{
_Cell.BackgroundColor = UIColor.FromPatternImage(CellBackgroundImage);
}
else
{
_Cell.BackgroundColor = UIColor.White;
}
ConfigureBackgroundImage();
_Cell.SetNeedsDisplay();
}