public void Format() { // prepare the arrays with the desired component sizes // ... // determine where the breaks are: rows = wrappingStrategy.Format(componentsStream); Draw(); }
public void Format() { // prepare the arrays with the desired component sizes // ... // rebuild the rows filed switch (textWrapping) { case TextWrapping.Inline: rows = InlineWrapping(); break; case TextWrapping.Tight: rows = TightWrapping(); break; case TextWrapping.Center: rows = CenterWrapping(); break; // ... } Draw(); }