GithubHelp home page GithubHelp logo

lele8446 / cjlabel Goto Github PK

View Code? Open in Web Editor NEW
182.0 6.0 27.0 7.26 MB

A drop-in replacement for UILabel that supports NSAttributedString, rich text, display any view, links, select copy and more

License: MIT License

Objective-C 99.13% Ruby 0.59% C 0.28%
uilabel attributedtext label coretext nsattributedstring copy-paste select

cjlabel's Issues

当键盘弹出,长按文本,不会显示menuVC

其实就是键盘和UIMenuController的并存问题:
1.需要增加一个自定义的TextView,支持设置nextResponder
2.CJLabel需要增加一个长按的回调或者通知,让业务层去监听当前谁即将成为Responder, 业务层去设置TextView的nextResponder
3.自定义的TextView需要监听UIMenuController的生命周期,取消nextResponder

NSMutableParagraphStyle,行间距设置

NSMutableParagraphStyle行间距设置,没有效果

代码如下
NSMutableParagraphStyle *paragraphStyleLineS = [[NSMutableParagraphStyle alloc] init];
paragraphStyleLineS.lineSpacing = 2.0; // 设置行间距

[attributes setValue:paragraphStyleLineS forKey:NSParagraphStyleAttributeName];

configure.attributes = attributes;

Emoji表情,多行时,无法显示全部内容

Hello,我这边出现,在iOS 9、10系统,emoji表情显示不会填充满Label,导致内容无法全部显示
多行时,内容会提前换行,每行,Label的宽度足以再放入一个emoji表情,但是却直接换行了,导致计算出来的高度,与实际展示需要的高度不一致,

点击图片怎么获取

你好: 我在文本后面用NSTextAttachment 添加了图片,想要获取图片点击事件 怎么处理 ? 谢谢

编译报错

CJLabelConfigure.h中 CTLineRef lastVisibleLine = CFArrayGetValueAtIndex(lines, lastVisibleLineIndex); 报错提示:Cannot initialize a variable of type 'CTLineRef' (aka 'const __CTLine *') with an rvalue of type 'const void *'

hi

当 文本是中文英文,数字的时候字体大小不一样阿

能否做一个只有长按选择复制的UIlabel扩展?

现有bug: numberOfLines大于0且小于实际label.numberOfLines,同时verticalAlignment不等于CJContentVerticalAlignmentTop时,文本显示位置有偏差

您的这个三方库这个问题太致命了, 会导致布局紊乱. 我这边只需要您的库的选择复制功能.

报错

pod下来后- (void)touchesCancelled:(nullable NSSet<UITouch *> *)touches withEvent:(nullable UIEvent *)event报错

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.