All Projects → CrabMen → Cminputview

CrabMen / Cminputview

Licence: mit
💪之前代码是基于UITextView进行的封装,侵入性较强,不方便使用,现使用Category重构代码,支持Cocoapods

Projects that are alternatives of or similar to Cminputview

Listplaceholder
ListPlaceholder is a swift library allows you to easily add facebook style animated loading placeholder to your tableviews or collection views.
Stars: ✭ 511 (+242.95%)
Mutual labels:  cocoapods, placeholder
Notepad
[iOS] A fully themeable markdown editor with live syntax highlighting.
Stars: ✭ 705 (+373.15%)
Mutual labels:  cocoapods, uitextview
Growingtextview
An UITextView in Swift. Support auto growing, placeholder and length limit.
Stars: ✭ 683 (+358.39%)
Mutual labels:  placeholder, uitextview
Skyfloatinglabeltextfield
A beautiful and flexible text field control implementation of "Float Label Pattern". Written in Swift.
Stars: ✭ 3,907 (+2522.15%)
Mutual labels:  cocoapods, textfield
Uitextview Placeholder
A missing placeholder for UITextView
Stars: ✭ 1,317 (+783.89%)
Mutual labels:  placeholder, uitextview
Tweetextfield
Lightweight set of text fields with nice animation and functionality. 🚀 Inspired by https://uimovement.com/ui/2524/input-field-help/
Stars: ✭ 421 (+182.55%)
Mutual labels:  cocoapods, textfield
Kmplaceholdertextview
A UITextView subclass that adds support for multiline placeholder written in Swift.
Stars: ✭ 696 (+367.11%)
Mutual labels:  placeholder, uitextview
LycricsTextView
No description or website provided.
Stars: ✭ 14 (-90.6%)
Mutual labels:  uitextview, textfield
Inputaccessoryview
Input Accessory View for Commenting and Chat User Interfaces built in Swift, if you like it please "☆"
Stars: ✭ 39 (-73.83%)
Mutual labels:  placeholder, uitextview
Taniwhatextfield
My first cocoapod framework
Stars: ✭ 26 (-82.55%)
Mutual labels:  cocoapods, textfield
Anyformatkit
Simple text formatting in Swift
Stars: ✭ 296 (+98.66%)
Mutual labels:  cocoapods, uitextview
Tkkeyboardcontrol
TKKeyboardControl adds keyboard awareness and scrolling dismissal (like iMessages app) to any view with only 1 line of code for Swift.
Stars: ✭ 110 (-26.17%)
Mutual labels:  cocoapods, textfield
Passwordtextfield
A custom TextField with a switchable icon which shows or hides the password and enforce good password policies
Stars: ✭ 281 (+88.59%)
Mutual labels:  cocoapods, textfield
Uitextfield Navigation
🏄‍♂️ UITextField-Navigation makes it easier to navigate between UITextFields and UITextViews
Stars: ✭ 436 (+192.62%)
Mutual labels:  cocoapods, uitextview
Skeletonui
☠️ Elegant skeleton loading animation in SwiftUI and Combine
Stars: ✭ 275 (+84.56%)
Mutual labels:  cocoapods, placeholder
Uiimageview Letters
UIImageView category for using initials as a placeholder image, written in Objective-C. For a Swift implementation, see https://github.com/bachonk/InitialsImageView
Stars: ✭ 694 (+365.77%)
Mutual labels:  cocoapods, placeholder
STTextView
📝 STTextView is a light-weight library that adds a placeholder to the UITextView.
Stars: ✭ 36 (-75.84%)
Mutual labels:  placeholder, uitextview
TextInputLayout
The objective of this code is to guide you to create login screen with TextInputLayout in iOS app.
Stars: ✭ 30 (-79.87%)
Mutual labels:  placeholder, textfield
Crboxinputview
Verify code input view. Support security type for password.短信验证码输入框,支持密文模式
Stars: ✭ 749 (+402.68%)
Mutual labels:  placeholder, uitextview
Pincodeinputview
A input text view for entering pin code.
Stars: ✭ 108 (-27.52%)
Mutual labels:  cocoapods, uitextview

DECLARATION:

Because the original code use inheritance which is too intrusive, now I use category to reconstruct the code, and released new version 。

Table of contents

Screenshots

效果展示

Installation

CocoaPods:

  • For iOS8+:
use_frameworks!
target '<Your Target Name>' do
    pod 'UITextView+CMInputView'
end

Manually:

  • Drag all files under CMInputView/CMInputView/Class folder into your project.

Pre-knowledge

Example

Firstly, you need import the .h file.

if cocoaposd:

#import <UITextView+CMInputView.h>

if manually:

#import "UITextView+CMInputView.h"

Then create UITextView and use this category to configure .

    UITextView * inputView = [[UITextView alloc]initWithFrame:CGRectMake(0, 100, self.view.bounds.size.width, 55)];
    inputView.font = [UIFont systemFontOfSize:18];
    
    inputView.cm_placeholder =  @"UITextView+CMInputView";
    inputView.cm_placeholderColor = [UIColor redColor];
    inputView.cm_maxNumberOfLines = 3;
    
    [self.view addSubview:inputView];

If you want to make the UITextView break line automatically ,you can write like this:

    UITextView * inputView = [[UITextView alloc]initWithFrame:CGRectMake(0, 100, self.view.bounds.size.width, 55)];
    inputView.font = [UIFont systemFontOfSize:18];
   
    inputView.cm_placeholder =  @"UITextView+CMInputView";
    inputView.cm_placeholderColor = [UIColor redColor];
    inputView.cm_autoLineBreak = YES;
    
    [self.view addSubview:inputView];

Congratulations! You're done. 🎉

Notes

  • The category do not support constrained layout,please use carefully !
  • Once you set cm_maxNumberOfLines ,the effect always works,even if you set YES to cm_autoLineBreak

Support this repo

  • ★Star this repo
  • If you find somes bugs or need some new functions,please Issue me

License

"UITextView+CMInputView" is available under the MIT license. See the LICENSE file for more info.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].