EmojiBoard class
The emojiboard has a configurable textfield which is will control It has a configurable height and it can be made visible or invisible using the showKeyboard boolean It also has a darkmode for the users with a good taste in styling.
- Inheritance
-
- Object
- State<
EmojiKeyboard> - EmojiBoard
Constructors
Properties
-
bottomBarStateKey
→ GlobalKey<
BottomBarState> -
final
- bromotionController ↔ TextEditingController?
-
getter/setter pair
-
categoryBarStateKey
→ GlobalKey<
CategoryBarState> -
final
- context → BuildContext
-
The location in the tree where this widget builds.
no setterinherited
- darkMode ↔ bool
-
getter/setter pair
- emojiKeyboardHeight ↔ double
-
getter/setter pair
-
emojiPageStateKey
→ GlobalKey<
EmojiPageState> -
final
- focusSearchEmoji ↔ FocusNode
-
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- mounted → bool
-
Whether this State object is currently in a tree.
no setterinherited
-
recent
↔ List<
Emoji> -
getter/setter pair
-
recentEmojis
↔ List<
String> -
getter/setter pair
- rememberPosition ↔ TextSelection
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- searchController → TextEditingController
-
final
-
searchedEmojis
↔ List<
String> -
getter/setter pair
- searchMode ↔ bool
-
getter/setter pair
- showBottomBar ↔ bool
-
getter/setter pair
- storage ↔ Storage
-
getter/setter pair
- widget → EmojiKeyboard
-
The current configuration.
no setterinherited
Methods
-
activate(
) → void -
Called when this object is reinserted into the tree after having been
removed via deactivate.
inherited
-
addRecentEmoji(
String emoji, int category) → void - If the user presses an emoji it is added to it's "recent" list. This is a list of emojis in a local db It looks to see if it is present in the 'recent emoji' list. If that is true than it should be in the database and we update it. If that is not true, we add a new entry for the database. When it adds a new entry it will look in the emoji list for the category that the emoji is in to be able to store a new entry in the local db
-
addRecentEmojiSearch(
String emoji) → dynamic -
The add recent emoji search does the same as the
addRecentEmoji
function But here we don't have access to the category, so we will loop through all the categories to find the emoji we want to add -
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
categoryHandler(
int categoryNumber) → void - This function handles any changes to the category from the category bar and passes it to the emoji page widget.
-
deactivate(
) → void -
Called when this object is removed from the tree.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
didChangeDependencies(
) → void -
Called when a dependency of this State object changes.
inherited
-
didUpdateWidget(
covariant EmojiKeyboard oldWidget) → void -
Called whenever the widget configuration changes.
inherited
-
dispose(
) → void -
Called when this object is removed from the tree permanently.
override
-
emojiScrollShowBottomBar(
bool emojiScrollShowBottomBar) → void - This function handles any triggers to hide or show the bottom bar if the user scrolls up or down on the emoji page. It sends this trigger to the bottom bar
-
emojiSearch(
) → void - If the user presses the "search" button this function is called. It sets the initial emojis, which is the recent page. It remembers the position that the cursor was at and it will shift focus to the new keyboard which will be called up.
-
getAvailableEmojis(
dynamic emojis) → Future - If the emoji cannot be shown in this Android version it is removed from the list.
-
initState(
) → void -
Called when this object is inserted into the tree.
override
-
insertText(
String myText, int category) → void - If the user selects an emoji from the grid a trigger is send to this function with the corresponding emoji that the user pressed. The emoji is added to the Textfield at the location of the cursor or as a replacement of the selection of the user.
-
insertTextSearch(
String myText) → void - If the user has searched for an emoji using the search functionality it can select any emoji and it will insert this emoji in the Textfield. It will then go out of search mode and back to the emoji keyboard. The emoji is added where the cursor was when the user pressed search.
-
isAvailable(
dynamic recentEmojis) → dynamic - This function is called when we want to see if any of the recent emojis that the user used can be shown in this Android version.
-
isPortrait(
) → bool -
myInterceptor(
bool stopDefaultButtonEvent, RouteInfo info) → bool - We intercept any back button trigger. If the user has the emoji keyboard open it will first override the back functionality by just hiding the emoji keyboard first. If the back button is called again the normal back functionality will apply.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
pressedBackSearch(
) → dynamic -
reassemble(
) → void -
Called whenever the application is reassembled during debugging, for
example during hot reload.
inherited
-
setInitialSearchEmojis(
) → dynamic - The function which will set the initial search emojis when the "search" button is pressed. It takes the recent emojis and fills it in. It stops after 10 because more is not needed.
-
setState(
VoidCallback fn) → void -
Notify the framework that the internal state of this object has changed.
inherited
-
switchedPage(
int pageNumber) → void - This function handles changes in the Emoji page if the user swipes left or right. It sends a trigger to the category bar to update the category
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringShort(
) → String -
A brief description of this object, usually just the runtimeType and the
hashCode.
inherited
-
updateEmojiSearch(
String text) → dynamic - Every letter that the user inputs in the search mode will trigger this function. It will take the text entered so far and find all emojis which are related to that text search in any way. It puts these emojis in the list and shows it.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- platform → const MethodChannel
- The name of the channel that Android will call when adding an emoji. This function will see if it can be shown in the Android version that the user is currently using. (See MainActivity in the android project for the implementation)