public class TuEditTextFragment extends TuEditTextFragmentBase implements StickerView.StickerViewDelegate
限定符和类型 | 类和说明 |
---|---|
static interface |
TuEditTextFragment.TuEditTextFragmentDelegate
图片编辑贴纸选择控制器委托
|
限定符和类型 | 字段和说明 |
---|---|
protected android.view.View.OnClickListener |
mButtonClickListener
按钮点击事件
|
mScreenSizeScale
permissionAlertDelegate
构造器和说明 |
---|
TuEditTextFragment()
图片编辑贴纸选择控制器
|
限定符和类型 | 方法和说明 |
---|---|
protected void |
asyncLoadImageCompleted(android.graphics.Bitmap image)
异步加载图片完成
|
protected boolean |
asyncNotifyProcessing(TuSdkResult result)
异步通知处理结果
|
boolean |
canAppendSticker(StickerView view,
StickerData sticker)
检查是否允许使用贴纸
|
protected void |
dispatcherViewClick(android.view.View v)
分发视图点击事件
|
TuSdkTextButton |
getAddStickerButton()
添加贴纸按钮
|
TuSdkTextButton |
getAlignCenterStyleButton()
样式栏中居中对齐设置按钮
|
TuSdkTextButton |
getAlignLeftStyleButton()
样式栏中左对齐设置按钮
|
TuSdkTextButton |
getAlignRightStyleButton()
样式栏中右对齐设置按钮
|
android.widget.RelativeLayout |
getBottomBar()
底部栏视图
|
TuSdkImageButton |
getCancelButton()
取消按钮
|
float |
getColorBarHeight()
颜色列表的高度
|
float |
getColorBarPaddingTop()
颜色列表顶部 paddding
|
android.widget.RelativeLayout |
getColorBottomBar()
颜色和样式底部栏视图
|
TuSdkTextButton |
getColorButton()
颜色按钮
|
float |
getColorIndicatorHeight()
颜色指示器高度
|
float |
getColorIndicatorWidth()
颜色指示器宽度
|
TuSdkLinearLayout |
getColorParamWrapLayout()
颜色参数视图
|
TuSdkColorSelectorBar |
getColorSelectorBar()
颜色调节栏
|
TuSdkLinearLayout |
getColorWrapLayout()
颜色调节父视图
|
TuSdkImageButton |
getCompleteButton()
完成按钮
|
TuMaskRegionView |
getCutRegionView()
裁剪选区视图
|
TuEditTextFragment.TuEditTextFragmentDelegate |
getDelegate()
图片编辑贴纸选择控制器委托
|
TuSdkEditText |
getEditTextView()
文字输入框
|
android.widget.LinearLayout |
getFeatureBar()
样式栏
|
android.widget.ImageView |
getImageView()
图片视图
|
static int |
getLayoutId()
布局ID
|
TuSdkImageButton |
getParamBackButton()
返回按钮
|
StickerView |
getStickerView()
贴纸视图
|
StickerView.StickerViewDelegate |
getStickerViewDelegate()
贴纸视图委托
|
TuSdkTextButton |
getStyleButton()
样式按钮
|
android.widget.HorizontalScrollView |
getStyleWrapLayout()
样式调节父视图
|
java.lang.String |
getText()
获取文字内容
|
java.lang.String |
getTextColor()
文字颜色 (默认:#FFFFFF)
|
int |
getTextPaddings()
文字和边框间距 (默认: 10dp)
|
java.lang.String |
getTextShadowColor()
文字阴影颜色 (默认:#000000)
|
int |
getTextSize()
文字大小
|
TuSdkTextButton |
getToLeftStyleButton()
样式栏中从右到左设置按钮
|
TuSdkTextButton |
getToRightStyleButton()
样式栏中从左到右设置按钮
|
TuSdkTextButton |
getUnderlineStyleButton()
样式栏中下划线设置按钮
|
protected void |
handleAddStickerButton()
添加文字贴纸按钮
|
protected void |
handleAlignCenterStyleButton()
字体居中对齐按钮
|
protected void |
handleAlignLeftStyleButton()
字体左对齐按钮
|
protected void |
handleAlignRightStyleButton()
字体右对齐按钮
|
protected void |
handleColorButton()
打开颜色设置界面
|
protected void |
handleParamBackButton()
返回按钮
|
protected void |
handleStyleButton()
打开样式设置界面
|
protected void |
handleToLeftStyleButton()
设置字体从右到左
|
protected void |
handleToRightStyleButton()
设置字体从左到右
|
protected void |
handleUnderlineStyleButton()
设置下划线
|
protected void |
loadView(android.view.ViewGroup view)
loadView
|
protected void |
notifyProcessing(TuSdkResult result)
通知处理结果
|
void |
onCancelAllStickerSelected()
轻触屏幕, 取消所有贴纸选中状态
|
android.view.View |
onCreateView(android.view.LayoutInflater inflater,
android.view.ViewGroup container,
android.os.Bundle savedInstanceState)
创建视图
|
void |
onStickerCountChanged(StickerData stickerData,
StickerItemViewInterface stickerItemViewInterface,
int operation,
int count)
贴纸数量改变
|
void |
onStickerItemViewReleased()
当贴纸被松开时
|
void |
onStickerItemViewSelected(StickerData stickerData,
java.lang.String text,
boolean needReverse)
当贴纸被选中时
|
protected void |
selectedIndex(TuSdkTextButton button)
选中颜色调节栏中的 index
|
void |
setColorBarHeight(float height)
颜色列表的高度
|
void |
setColorBarPaddingTop(float padding)
颜色列表顶部 paddding
|
void |
setColorIndicatorHeight(float height)
颜色指示器高度
|
void |
setColorIndicatorWidth(float width)
颜色指示器宽度
|
void |
setDelegate(TuEditTextFragment.TuEditTextFragmentDelegate mDelegate)
图片编辑贴纸选择控制器委托
|
protected void |
setImageRegionMask(android.graphics.Bitmap image)
设置图片选区遮罩
|
void |
setStickerViewDelegate(StickerView.StickerViewDelegate mStickerViewDelegate)
贴纸视图委托
|
void |
setText(java.lang.String mText)
设置文字内容
|
void |
setTextColor(java.lang.String textColor)
文字颜色 (默认:#FFFFFF)
|
void |
setTextPaddings(int mTextPaddings)
文字和边框间距 (默认: 10dp)
|
void |
setTextShadowColor(java.lang.String mTextShadowColor)
文字阴影颜色 (默认:#000000)
|
void |
setTextSize(int mTextSize)
文字大小
|
protected void |
viewDidLoad(android.view.ViewGroup view)
初始化视图
|
appendStickerItem, asyncEditWithResult, handleBackButton, handleCompleteButton, toggleTextReverse, updateText
asyncLoadImage, getCuterImage, getCuterImage, getImage, getImageDisplaySize, getImageSqlInfo, getPreview, getTempFilePath, handleTest, isAutoRemoveTemp, isShowResultPreview, loadImageWithThread, loadOrginImage, onDestroyView, postProcessWithImage, preProcessWithImage, processingImage, setAutoRemoveTemp, setImage, setImageSqlInfo, setShowResultPreview, setTempFilePath, showResultPreview
addWaterMarkToImage, asyncProcessingIfNeedSave, backUIThreadNotifyProcessing, canSaveFile, getOutputCompress, getSaveToAlbumName, getWaterMarkOption, isSaveToAlbum, isSaveToTemp, saveToAlbum, saveToTemp, setOutputCompress, setSaveToAlbum, setSaveToAlbumName, setSaveToTemp, setWaterMarkOption
getErrorListener, getRequestPermissionCode, getRequiredPermissions, hasRequiredPermission, notifyError, onPermissionGrantedResult, onRequestPermissionsResult, requestRequiredPermissions, setErrorListener
alert, alert, filpModalNavigationActivity, filpModalNavigationActivity, hubDismiss, hubDismissRightNow, hubError, hubError, hubStatus, hubStatus, hubSuccess, hubSuccess, initCreateView, onDetach, presentActivity, presentModalNavigationActivity, presentModalNavigationActivity, presentModalNavigationActivity, pushModalNavigationActivity, pushModalNavigationActivity, setNavLeftButton, setNavLeftButton, setNavLeftButton, setNavLeftHighLightButton, setNavLeftHighLightButton, setNavRightButton, setNavRightButton, setNavRightButton, setNavRightHighLightButton, setNavRightHighLightButton
addOrientationListener, backStackEntryCount, bindSoftInputEvent, dismissActivity, dismissActivityWithAnim, dismissActivityWithAnim, equalViewIds, filpModalNavigationActivity, getDismissAnimType, getNavButton, getOriginFragment, getResColor, getResString, getResString, getResString, getResString, getRootView, getRootViewLayoutId, getSdkActivity, getTitle, getViewById, getViewById, getViewId, isBackButtonShowed, isFragmentPause, isFullScreen, isSupportSlideBack, navigatorBarBackAction, navigatorBarCancelAction, navigatorBarHeight, navigatorBarLeftAction, navigatorBarLoaded, navigatorBarRightAction, navSearchViewSearch, navSearchViewSetDelegate, navSegmentedAddTexts, navSegmentedAddTexts, navSegmentedSetDelegate, navSegmentedSetected, onAttach, onBackForSlide, onBackPressed, onCreateAnimation, onDestroy, onFragmentAnimationEnd, onKeyUp, onNavigatorBarButtonClicked, onOrientationChanged, onPause, onPauseFragment, onPreDraw, onRefreshData, onResume, onResumeFragment, popFragment, popFragment, popFragmentRoot, presentActivity, presentActivity, presentModalNavigationActivity, presentModalNavigationActivity, presentModalNavigationActivity, pushFragment, refreshOriginFragment, replaceFragment, runOnUiThread, setIsSupportSlideBack, setNavigatorBarId, setNavigatorBarOnButtom, setNavLeftButton, setNavLeftButton, setNavRightButton, setNavRightButton, setOriginFragment, setRequestedOrientation, setRootViewLayoutId, setTitle, setTitle, showBackButton, showNavigatorBar, showView, showViewIn, wantFullScreen
dump, equals, getActivity, getAllowEnterTransitionOverlap, getAllowReturnTransitionOverlap, getArguments, getChildFragmentManager, getContext, getEnterTransition, getExitTransition, getFragmentManager, getHost, getId, getLayoutInflater, getLayoutInflater, getLifecycle, getLoaderManager, getParentFragment, getReenterTransition, getResources, getRetainInstance, getReturnTransition, getSharedElementEnterTransition, getSharedElementReturnTransition, getString, getString, getTag, getTargetFragment, getTargetRequestCode, getText, getUserVisibleHint, getView, getViewLifecycleOwner, getViewLifecycleOwnerLiveData, getViewModelStore, hashCode, hasOptionsMenu, instantiate, instantiate, isAdded, isDetached, isHidden, isInLayout, isMenuVisible, isRemoving, isResumed, isStateSaved, isVisible, onActivityCreated, onActivityResult, onAttach, onAttachFragment, onConfigurationChanged, onContextItemSelected, onCreate, onCreateAnimator, onCreateContextMenu, onCreateOptionsMenu, onDestroyOptionsMenu, onGetLayoutInflater, onHiddenChanged, onInflate, onInflate, onLowMemory, onMultiWindowModeChanged, onOptionsItemSelected, onOptionsMenuClosed, onPictureInPictureModeChanged, onPrepareOptionsMenu, onSaveInstanceState, onStart, onStop, onViewCreated, onViewStateRestored, postponeEnterTransition, registerForContextMenu, requestPermissions, requireActivity, requireContext, requireFragmentManager, requireHost, setAllowEnterTransitionOverlap, setAllowReturnTransitionOverlap, setArguments, setEnterSharedElementCallback, setEnterTransition, setExitSharedElementCallback, setExitTransition, setHasOptionsMenu, setInitialSavedState, setMenuVisibility, setReenterTransition, setRetainInstance, setReturnTransition, setSharedElementEnterTransition, setSharedElementReturnTransition, setTargetFragment, setUserVisibleHint, shouldShowRequestPermissionRationale, startActivity, startActivity, startActivityForResult, startActivityForResult, startIntentSenderForResult, startPostponedEnterTransition, toString, unregisterForContextMenu
public static int getLayoutId()
public TuEditTextFragment.TuEditTextFragmentDelegate getDelegate()
public void setDelegate(TuEditTextFragment.TuEditTextFragmentDelegate mDelegate)
public android.view.View onCreateView(android.view.LayoutInflater inflater, android.view.ViewGroup container, android.os.Bundle savedInstanceState)
TuFragment
onCreateView
在类中 TuFragment
protected void notifyProcessing(TuSdkResult result)
notifyProcessing
在类中 TuResultFragment
result
- SDK处理结果protected boolean asyncNotifyProcessing(TuSdkResult result)
asyncNotifyProcessing
在类中 TuResultFragment
result
- SDK处理结果public android.widget.ImageView getImageView()
public StickerView getStickerView()
getStickerView
在类中 TuEditTextFragmentBase
public TuMaskRegionView getCutRegionView()
getCutRegionView
在类中 TuEditTextFragmentBase
public TuSdkEditText getEditTextView()
public android.widget.LinearLayout getFeatureBar()
public TuSdkColorSelectorBar getColorSelectorBar()
public TuSdkLinearLayout getColorParamWrapLayout()
public TuSdkLinearLayout getColorWrapLayout()
public android.widget.HorizontalScrollView getStyleWrapLayout()
public TuSdkTextButton getColorButton()
public TuSdkTextButton getStyleButton()
public TuSdkImageButton getCancelButton()
public TuSdkImageButton getCompleteButton()
public TuSdkTextButton getToLeftStyleButton()
public TuSdkTextButton getToRightStyleButton()
public TuSdkTextButton getUnderlineStyleButton()
public TuSdkTextButton getAlignLeftStyleButton()
public TuSdkTextButton getAlignRightStyleButton()
public TuSdkTextButton getAlignCenterStyleButton()
public android.widget.RelativeLayout getBottomBar()
public android.widget.RelativeLayout getColorBottomBar()
public TuSdkImageButton getParamBackButton()
public TuSdkTextButton getAddStickerButton()
protected void dispatcherViewClick(android.view.View v)
protected void selectedIndex(TuSdkTextButton button)
protected void handleStyleButton()
protected void handleColorButton()
protected void handleParamBackButton()
protected void handleAddStickerButton()
protected void handleUnderlineStyleButton()
protected void handleToLeftStyleButton()
protected void handleToRightStyleButton()
protected void handleAlignLeftStyleButton()
protected void handleAlignRightStyleButton()
protected void handleAlignCenterStyleButton()
public StickerView.StickerViewDelegate getStickerViewDelegate()
public void setStickerViewDelegate(StickerView.StickerViewDelegate mStickerViewDelegate)
public java.lang.String getText()
public void setText(java.lang.String mText)
public int getTextPaddings()
public void setTextPaddings(int mTextPaddings)
public int getTextSize()
public void setTextSize(int mTextSize)
public java.lang.String getTextColor()
public void setTextColor(java.lang.String textColor)
textColor
- 文字颜色public java.lang.String getTextShadowColor()
public void setTextShadowColor(java.lang.String mTextShadowColor)
public float getColorBarHeight()
public void setColorBarHeight(float height)
public float getColorIndicatorWidth()
public void setColorIndicatorWidth(float width)
public float getColorIndicatorHeight()
public void setColorIndicatorHeight(float height)
public float getColorBarPaddingTop()
public void setColorBarPaddingTop(float padding)
protected void loadView(android.view.ViewGroup view)
loadView
在类中 TuEditTextFragmentBase
protected void viewDidLoad(android.view.ViewGroup view)
TuSdkFragment
viewDidLoad
在类中 TuEditTextFragmentBase
protected void asyncLoadImageCompleted(android.graphics.Bitmap image)
protected void setImageRegionMask(android.graphics.Bitmap image)
public boolean canAppendSticker(StickerView view, StickerData sticker)
StickerView.StickerViewDelegate
canAppendSticker
在接口中 StickerView.StickerViewDelegate
view
- 贴纸视图sticker
- 贴纸数据public void onCancelAllStickerSelected()
StickerView.StickerViewDelegate
public void onStickerCountChanged(StickerData stickerData, StickerItemViewInterface stickerItemViewInterface, int operation, int count)
StickerView.StickerViewDelegate
onStickerCountChanged
在接口中 StickerView.StickerViewDelegate
stickerData
- 当前变更的贴纸类operation
- 当前操作 0 删除 1 添加count
- 变化后的贴纸数量public void onStickerItemViewSelected(StickerData stickerData, java.lang.String text, boolean needReverse)
StickerView.StickerViewDelegate
onStickerItemViewSelected
在接口中 StickerView.StickerViewDelegate
text
- 贴纸文本内容public void onStickerItemViewReleased()
StickerView.StickerViewDelegate