Autocomplete box display wrong direction and position.
Hi,
I've downloaded EgoTextView, it's great. It's a great textEditor I've ever seen. But I see a issue, if we can fix it, it's really fantastic.
- The autoComplete box display wrong direction of word (from bottom to top), it display the suggestion word wrong direction.
- When I change the font with new fontName and size, the autoComplete box display wrong direction and position.
Here is the code which I changed to EGOTextView_DemoViewController.m:
if (_egoTextView==nil) {
EGOTextView *view = [[EGOTextView alloc] initWithFrame:self.view.bounds];
view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
view.delegate = (id<EGOTextViewDelegate>)self;
[self.view addSubview:view];
self.egoTextView = view;
self.egoTextView.font = [UIFont fontWithName:@"Helvetica" size:25.0f];
[view release];
[view becomeFirstResponder];
}
I just set the font for egoTextView by this line: self.egoTextView.font = [UIFont fontWithName:@"Helvetica" size:25.0f];
Then I run on iPad 5.0, when I write my text, the autoComplete box display wrong on both of direction and position.
The textEditor would be better if we can fix it.
Thanks in advance and waiting the fix.
In case someone is looking for a solution. I'm not saying it is the best one, but that's all I could find after several hours, in EGOContentView implementation :
-
(void) layoutSubviews { [super layoutSubviews];
for (CALayer * layer in self.layer.sublayers) { layer.geometryFlipped = YES; }
[self.delegate textChanged]; // reset layout on frame / orientation change
}
thanks @aimak this works with charm but i am still having another issue with the autoComplete box origin. This box displayed at wrong position