Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

StyledMultilineElement shows gaps with large text values and disappears altogether with really large values. #225

Open
GavinSutherland opened this issue May 9, 2014 · 0 comments

Comments

@GavinSutherland
Copy link

Hi,

If the text being shown in a StyledMultilineElement is of any great length then the Caption and the text is being shown further down (image attached). This problem gets worse if your text string is really big, say about 20,000 characters, because you get a huge scrolling cell with no text in it at all. Simplified version of the code I'm using in my UITapGestureRecognizer:

RootElement root = new RootElement("Title") { UnevenRows = true };
var section = new Section("Section Heading");
// Get a value string that is approx 1,000 chars long
var value = GetLongString();

var element = new StyledMultilineElement("Caption", value, UITableViewCellStyle.Subtitle)
{
    LineBreakMode = UILineBreakMode.WordWrap,
    Font = UIFont.FromName("HelveticaNeue", 16f),
    SubtitleFont = UIFont.FromName("HelveticaNeue", 16f)
};
section.Add(element);
root.Add(new List<Section>() { section });

var viewController = new DialogViewController(root);
var navbarController = new UINavigationController(viewController);

_contactPopup = new UIPopoverController(navbarController);
_contactPopup.PresentFromRect(cell.Bounds, cell, UIPopoverArrowDirection.Any, true);

multilinegap

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant