Hi,Developer,Welcome to use SuperTextView !

Overview

GitAds

GitAds

Hello, Developer!Welcome to use SuperTextView

English | 中文

SuperTextView

Hi,Developer,Welcome to use SuperTextView

Thank you and tens of thousands of Android developers for your trust in me 😘

SuperTextView is different in that it is just a simple view element, but not just a view.

It's alive and dynamic, with powerful embedded logic that continues to provide you with rich but exceptionally simple development support.

SuperTextView saves you from complex rendering logic. A simple API method call, the dazzling rendering effects are instantly available.

You just enjoy the amazing visual effects you have written, and the rest will be handed over to SuperTextView.

Feature

  • set rounded corners for View
  • supports separate control of each rounded corner
  • add border for View
  • add a stroke or hollow effect to the text
  • support up to 2 Drawable to display
  • accurately control the size and position of Drawable
  • support gradient background
  • touch discoloration
  • display pictures, including the net pictures
  • set rounded corners for pictures
  • add borders to pictures
  • Adjuster module can insert operation
  • change the color of Drawable
  • change the rotation of Drawable
  • support text gradient effect
  • support for setting click events separately for the Drawable zone
  • support Gif display
  • support for adding borders to Gif, as well as rounded corners
  • support Gif pause/play, modify frame rate
  • support for extracting the specified Gif frame
  • ...

Demo

📲 click here (or scan the qr code below) to download the Demo

SuperTextView

Portal Area

Usage

Add it in you build.gradle:

allprojects {
    repositories {
        ...
        maven { url 'https://jitpack.io' }
    }
}

dependencies {
    compile 'com.github.chenBingX:SuperTextView:VERSION_CODE'
}

The version code of the latest release can be found here.

Special Note 💡

  • v3.2.5 support:armeabi-v7a

  • v3.2.5.64 support:armeabi-v7aarm64-v8a

  • v3.2.5.99 support:armeabi-v7aarm64-v8ax86

  • ⚠️ Attention: proguard-rules.pro please add -keep class com.coorchice.library.gifdecoder.JNI { *; }

Update Log

v3.2.5

  • 【fix】 stv_pressBgColor invalid
  • 【fix】setDrawablePaddingLeft() not work
  • 【OP】Clear log
  • 【New】Support cache gif by the GifCache
  • 【OP】Optimize Gif rendering efficiency

v3.2.4

  • Fix Drawable directly write hexadecimal color value, does not display the problem

  • Drawable Support for specified layer

    <com.coorchice.library.SuperTextView
        ...
        // Configuring the level of Drawable1
        app:stv_state_drawable_layer="beforeText"
        // Configuring the level of Drawable2
        app:stv_state_drawable2_layer="afterText"
        ...
        />
    

    Support mode:

      - `beforeText`,Before the text
      - `afterText`,After the text
    

    Java has corresponding functions to support dynamic configuration.

  • Scale mode scaleType switch invalidation problem when fixing Drawable1 as background image

v3.2.3

  • Optimize text strokes

  • Optimize the display of transparent gif

v3.2.1 - Great,SuperTextView

In the new v3.2.0 version, SuperTextView redefines itself again. Developers, take a look at the surprises prepared for you! 🎉 🎉 🎉

this is... Gif ?

This time, SuperTextView brings powerful Gif driver support to developers.

If in the past, you have been upset about how to display a Gif chart on the Android platform, or you are stuck in the performance abyss of some three-party Gif libraries. But now, SuperTextView will completely change this situation.

Gif and SuperTextView are natural and natural, so you can display a Gif diagram in the most familiar and natural way. It's as simple as showing a normal picture as usual.

Thanks to the ultra-high performance of c/c++ and the precise operation of memory. SuperTextView Customized the powerful Gif driver engine for mobile platforms by using c/c++.

SuperTextView's Gif engine, which can accurately manipulate image pixel memory, only update local pixel memory when frame refresh of Gif image, which makes Gif image rendering efficiency Got a qualitative leap.

Through asynchronous off-screen rendering technology, SuperTextView can ensure smooth and smooth application interface and sensitive response speed even when displaying large Gif images.

💡 In the above Demo, using SuperTextView shows a Gif image with a 265 frame image, but the user interface is still very smooth.

Display Gif super simple

Display a Gif diagram in SuperTextView, super easy!

You can configure it directly in the XML layout document or add it in your code.

Configuring Gif in XML
<com.coorchice.library.SuperTextView
    android:id="@+id/stv_1"
    android:layout_width="match_parent"
    android:layout_height="150dp"
    app:stv_state_drawable="@drawable/gif_1" />

You can display the Gif diagram for the SuperTextView configuration just like configuring a normal image.

Configuring Gif in your code
stv_1 = (SuperTextView) findViewById(R.id.stv_1);
stv_1.setDrawable(R.drawable.gif_1);

It's that simple and natural, SuperTextView allows developers to display a Gif diagram without any awareness.

In the kernel logic of SuperTextView, SuperTextView intelligently classifies the normal graph and Gif graph, and then processes and optimizes accordingly.

Display network Gif is as simple

What if your Gif is not local but in the cloud?

You don't have to worry about it!Everything is handed over to SuperTextView.

stv_1 = (SuperTextView) findViewById(R.id.stv_1);
stv_1.setUrlImage("http://example.com/images/example.gif");

With just one line of code, SuperTextView will assist you in the background to load the Gif image and then process the rendering to the screen.

💡 In fact, the Drawable1 and Drawable2 image display bits of SuperTextView can be used to display Gif images. In short, everything is what you are familiar with.

You can control more

SuperTextView not only display Gif, but also you can control more details.

Play / Pause

You can control Gif , play, or pause at any time.

if (stv.getDrawable() instanceof GifDrawable) {
  // Get the GifDrawable first
  GifDrawable gifDrawable = (GifDrawable) stv.getDrawable();

  // Play
  gifDrawable.play();

  // Pause
  gifDrawable.stop();
}

Jump/Get the specified frame

In SuperTextView, you can always reach the image of the frame you specify, as well as the image that can be extracted to the specified frame.

if (stv.getDrawable() instanceof GifDrawable) {
  // Get the GifDrawable first
  GifDrawable gifDrawable = (GifDrawable) stv.getDrawable();

  // Jump to the specified frame
  gifDrawable.gotoFrame(pre);

  // Get the specified frame
  Bitmap frame = gifDrawable.getFrame(i);
}

💡 Since SuperTextView can support local incremental rendering, when your Gif supports this rendering mode, it means you may need to enable ** strict mode by calling gifDrawable.setStrict(true) , to ensure that the frame jump or frame extraction image is correct. This can take some time, so you should try to do the operations under ** strict mode* in an asynchronous thread.

Fast, follow your heart

SuperTextView allows you to modify the playback rate of the Gif chart at will.

if (stv.getDrawable() instanceof GifDrawable) {
  // Get the GifDrawable first
  GifDrawable gifDrawable = (GifDrawable) stv.getDrawable();

  // Set the frame playback interval, 20 ms
  gifDrawable.setFrameDuration(20);
}

You can know all

With SuperTextView you can get a glimpse of the information of a Gif.

  • Get Gif size

    // Get width
    int width = gifDrawable.getWidth();
    
    // Get height
    int height = gifDrawable.getHeight();
    
  • Get Gif frame information

    // Get the number of frames
    int frameCount = gifDrawable.getFrameCount();
    
    // Get the current frame interval
    int frameDuration = gifDrawable.getFrameDuration();
    
    // Get the current render to that frame
    int framePotision = gifDrawable.getCurrentFrame();
    
    // Whether it is playing
    boolean isPlaying = gifDrawable.isPlaying();
    

More brilliant Gif

** SuperTextView ** and ** Gif ** rendered by virtue of seamless integration, after ** Drawable1 ** and ** Drawable2 ** all configuration items in the display ** Gif ** Figure, too, can enter into force.

Gif as a normal Drawable
app:stv_state_drawable_rotate="90"

Let's take a look at what's going on with a Gif in the original Drawable position.

<com.coorchice.library.SuperTextView
    android:layout_width="match_parent"
    android:layout_height="50dp"
    android:paddingLeft="62dp"
    android:paddingRight="10dp"
    android:text="小火箭发射了!啦啦啦啦啦啦..."
    android:textColor="#ffffff"
    android:textSize="22dp"
    app:stv_corner="6dp"
    app:stv_isShowState="true"
    app:stv_solid="#0D1831"

    // set Gif
    app:stv_state_drawable="@drawable/gif_1"

    // set Gif height
    app:stv_state_drawable_height="40dp"

    // set Gif width
    app:stv_state_drawable_width="40dp"

    // set Gif to left
    app:stv_state_drawable_mode="left"

    // set Gif left spacing
    app:stv_state_drawable_padding_left="10dp"/>

The effect is...

Now let's try Gif to rotate 90 degrees.

<com.coorchice.library.SuperTextView
    ...
    // set Gif to rotate 90 degrees
    app:stv_state_drawable_rotate="90"
    ...
/>

Fillet the Gif

SuperTextView incredible implementation Gif The fillet of the graph opens a new door for developers.

However, the realization of this effect is amazingly simple.

<com.coorchice.library.SuperTextView
    android:layout_width="185dp"
    android:layout_height="138.75dp"
    android:layout_gravity="center_horizontal"
    app:stv_corner="20dp"

    // set Gif as the control background
    app:stv_drawableAsBackground="true"

    app:stv_scaleType="fitCenter"

    // Configuring Gif
    app:stv_state_drawable="@drawable/gif_1" />
Add a border to the Gif

Developers can even easily add a border to a Gif.

<com.coorchice.library.SuperTextView
    android:layout_width="350dp"
    android:layout_height="148.4dp"
    android:layout_gravity="center_horizontal"
    android:gravity="center"

    // add the text will be more stylish
    android:text="SuperTextView"

    android:textSize="36dp"
    android:textStyle="bold"
    android:visibility="invisible"
    app:stv_corner="6dp"
    app:stv_drawableAsBackground="true"
    app:stv_isShowState="true"
    app:stv_scaleType="center"
    // Set the border color
    app:stv_stroke_color="@color/opacity_8_gray_4c

    // Set the border width
    app:stv_stroke_width="5dp"

    app:stv_text_fill_color="#ccffffff"
    app:stv_text_stroke="true"
    app:stv_text_stroke_color="#cc000000"
    app:stv_text_stroke_width="2dp"

    // Configuring Gif
    app:stv_state_drawable="@drawable/gif_1"/>

The effect is instantly presented...

Easily implement dynamic avatars

In the past, some cool dynamics often stopped at the complexity and cost of implementation. And SuperTextView brings you more possibilities, and your inspiration can be free.

For example, the implementation of dynamic avatars will be simpler than ever.

<com.coorchice.library.SuperTextView
    android:layout_width="80dp"
    android:layout_height="80dp"
    android:layout_marginLeft="30dp"
    app:stv_corner="40dp"

    // Set as background image
    app:stv_drawableAsBackground="true"

    // Configure Gif avatar
    app:stv_state_drawable="@drawable/gif_avatar"

    // Add border
    app:stv_stroke_color="#ffffff"
    app:stv_stroke_width="3dp"
    />

In the code, you can configure a web dynamic avatar directly.

stv.setUrlImage("http://gif_avatar.gif");

More surprises

Both Drawables support clicks!

In the new version of SuperTextView, Drawable1 and Drawable2 are given new capabilities - support for precise clicks.

SuperTextView By monitoring the location where the click action occurs, the click action can be accurately located in the area where it occurred (Drawable1, Drawable2 or Other areas), then trigger accordingly Listening callbacks.

You can set the click action listener on Drawable for SuperTextView to make an accurate response when an action occurs.

stv.setOnDrawableClickedListener(new SuperTextView.OnDrawableClickedListener() {
    @Override
    public void onDrawable1Clicked(SuperTextView stv) {
        // Drawable1 clicked,do something...
    }
    @Override
    public void onDrawable2Clicked(SuperTextView stv) {
        // Drawable2 clicked,do something...
    }
});

stv.setOnClickListener(new View.OnClickListener() {
    @Override
    public void onClick(View v) {
        // Non-Drawable area is clicked, do something...
    }
});

Background image zoom mode support

Now, when you use Drawable1 as the background image, you can configure different zoom modes for it to achieve your favorite effect.

stv.setScaleType(ScaleType.CENTER);

SuperTextView provides developers with up to 3 zoom modes:

  • ScaleType.FIT_XY

    Stretch the picture to tile.

  • ScaleType.FIT_CENTER

    Center the image adaptively.

  • ScaleType.CENTER

    Crop the picture centered. Defaults.

Other updates

  • In the XML layout document, Drawable1 and Drawable2 now support direct setting color or ShapeDrawable.

    // Circle_f9ad36 is a shape file written in xml
    app:stv_state_drawable="@drawable/circle_f9ad36"
    
    // Use solid color as Drawable
    app:stv_state_drawable="#000000"
    
  • ⚠️ The minimum supported version API is promoted to 19.

  • Rendering performance is at least 30% better than in the past.

  • Upgrade the default image loading engine to support smart caching. Maybe now, you don't have to introduce a third-party image loading library.

v3.1.1 - Sincerity works,SuperTextView

SuperTextView was built to help Android developers develop Android applications more efficiently, conveniently, and elegantly.

Now the bona fides have escalated again. The new SuperTextView will open up more possibilities to Android developers, and, as always, SuperTextView will bring more efficient features.

1 Amazing coloring

image

This update to SuperTextView adds a magical and powerful coloring capability to StateDrawable. Developers can easily change the color of an icon without having to add a different color icon to the project. This technology will give your Android applications a chance to slim down.

# modify the drawable color
app:stv_state_drawable_tint="@color/gray"

# modify the drawable2 color
app:stv_state_drawable2_tint="@color/red"

With such a simple line of code, you can instantly give an picture the power to change. Any color you want is up to you, of course. All this happened without the need to introduce another picture.

In the Java code, there is a set / get function corresponding to it, so that developers can cast magic at any time, changing the color of a picture.

2 Seventy-two Metamorphoses;

StateDrawable's enhancements go beyond color transformations. SuperTextView has been given the ability to change StateDrawable's shape. With the same picture, developers can combine an infinite number of possibilities.

image

With a few lines of code, you can transform any picture as you wish.

# Modify the drawable's rotation
app:stv_state_drawable_rotate="90"

# Modify the drawable's rotation
app:stv_state_drawable2_rotate="90"

No need for complicated code, SuperTextView is as simple and elegant as ever.

Similarly, in Java code, the corresponding set/get function is also provided.

This ability can effectively help developers compress the volume of Android applications to the extreme.

3 Wonderful is far more than this

image

This is the gradient text!

What SuperTextView offers is probably the simplest and elegant solution for implementing gradient text so far. With a simple configuration, you can achieve cool gradient text effects.

# Whether to enable gradient text
app:stv_textShaderEnable="true"

# Set the starting color of the text
app:stv_textShaderStartColor="@color/red"

# Set the ending color of the text
app:stv_textShaderEndColor="@color/yellow"

# Set the gradient mode of the text
# leftToRight:left -> right
# rightToLeft:right -> left
# topToBottom:top -> bottom
# bottomToTop:bottom -> top
app:stv_textShaderMode="leftToRight"

These properties also provide the set/get interface in Java, making it easy for developers to modify them at any time.

4 New apis have been opened

4.1 Adjuster adds onAttach, onDetach

Adjuster added two new functions:

  • onAttach() : when Adjuster is set to a SuperTextView will be invoked.
  • onDetach() : when Adjuster is removed from a SuperTextView will be invoked.

By rewriting these two functions in Adjuster, the developer can perform state registration, initialization, unregistration, resource release and other operations at the right time.

public class MyAdjuster extends SuperTextView.Adjuster{

    @Override
    protected void adjust(SuperTextView superTextView, Canvas canvas) {

    }

    @Override
    public void onAttach(SuperTextView stv) {
      // will be called when the modifier is added to a SuperTextView
    }

    @Override
    public void onDetach(SuperTextView stv) {
      // will be called when the Adjuster is removed from SuperTextView
    }
}

4.2 Provide getAdjusterList() function

This function allows the developer to get all the Adjusters in a SuperTextView. If there is no Adjuster in the SuperTextView, it will return null.

5 ⚠️ You must take these changes seriously

5.1 Attribute with the stv_ prefix

All properties of SuperTextView are now prefixed with stv_.

This avoids conflicts with the property names that SuperTextView may generate when other third-party libraries are introduced by the developer.

If the developer is currently using a previous version of SuperTextView, then after upgrading to the new version, you need to prefix the attributes in all xml with the stv_ prefix.

app:corner="10dp"

corner is the name of the attribute in the old version. After upgrading to the new version, you need to add the stv_ prefix to the front and become stv_corner.

image

If the developer is using AndroidStudio, open the bulk replacement dialog from Edit > Find > Replace and follow the instructions below.

image

If only SuperTextView uses the same namespace (such as app) in the developer's project, then fortunately, you can simply replace app: with app:stv_.

5.2 setAdjuster(Adjuster) has been removed

Starting with SuperTextView v2.0, the setAdjuster(Adjuster) function is marked for the state to be removed, and the new function addAdjuster(Adjuster) is added instead.

In the new version, the setAdjuster(Adjuster) function will be officially removed. If the developer has used this method before, please change it to addAdjuster(Adjuster).

6 How to get started SuperTextView v3.1.1

dependencies {
	 compile 'com.github.chenBingX:SuperTextView:v3.1.1'
}

v3.0 - Your long-awaited SuperTextView

Today, SuperTextView has a range of common features such as fillets, borders, strokes, press discoloration, multi-state diagrams, fillet plots, versatile Adjuster, loading the net picture, and more. Thanks to this, developers can easily achieve a variety of very cumbersome effects, save a lot of development time, effectively reduce the complexity of the page, reduce project maintenance costs.

Write the code, it should be so pleasing!

1. Linked Cloud SuperTextView

As early as a few months ago, many developers have suggested to CoorChice whether it is possible to have SuperTextView with the ability to load net picture. In fact, this is also CoorChice has been considered a long time ago, but in the early days of SuperTextView, perfecting its core functions is still the primary goal, so it has not been involved in image-related functions.

Until the last big version, SuperTextView v2.0, CoorChie tried to add the picture display function. This has enabled the scope of the SuperTextView to be expanded, as well as the ability to add strokes, rounded corners, and state diagrams to pictures. Related documentation can be found at the following link:

【Hello, SuperTextView】 - https://www.jianshu.com/p/1b91e11e441d

This time, I got a good response from the developers. Everyone is looking forward to using SuperTextView to display and process picture. After the last release, developers seem to be more interested in a SuperTextView that can display the net picture.

So, now, the long-awaited SuperTextView is coming back!

1.1 Load a net picture

To display a net picture, you only need the following code in SuperTextView:

SuperTextView stv_1 = (SuperTextView) findViewById(R.id.stv_1);
// fill in the picture Url
stv_1.setUrlImage(url);

The effect is the same as the second example of displaying an avatar in the image above.

If you want to display the net picture as a StateDrawable of SuperTextView, it's fine.

// fill in the picture Url
stv_1.setUrlImage(url, false);

The second parameter is false to indicate that the net picture will not be filled with the entire SuperTextView as a background, but as a state diagram. Of course, everything about the state diagram will be used here. As in the first example above, the entire layout, including pictures, text, and background, is processed in a SuperTextView, and pictures downloaded from the net are placed as StateDrawable in the place.

1.2 Image engine in SuperTextView

SuperTextView In order to keep the library dependent on the purity and the smallest possible size, there is no built-in image load framework. So by default, a simple image engine built-in will be used to download pictures, to ensure that developers can use the ability to display the net picture.

However, CoorChice still recommends that developers choose a image loading framework that is currently in use, depending on the project, and set it to SuperTextView to load the picture. SuperTextView has the ability to adapt to any image load framework. Below CoorChice will show you how to install an existing image framework into SuperTextView with the Glide and the Picasso examples.

1.2.1 Implementing image engine

In SuperTextView, the core image loading engine is abstracted into the interface Engine, and the developer needs to implement a Engine depending on the image frame used.

  • the Glide Image load framework
public class GlideEngine implements Engine {

  private Context context;

  public GlideEngine(Context context) {
        this.context = context;
  }

  @Override
  public void load(String url, final ImageEngine.Callback callback) {
        Glide.with(context).load(url).into(new SimpleTarget<GlideDrawable>() {
        @Override
        public void onResourceReady(GlideDrawable resource, GlideAnimation<? super GlideDrawable> glideAnimation) {
            // mainly through the callback return Drawable object to SuperTextView
            callback.onCompleted(resource);
        }
        });
    }
}
  • the Picasso Image load framework
public class PicassoEngine implements Engine {

  private Context context;

  public PicassoEngine(Context context) {
        this.context = context;
  }

  @Override
  public void load(String url, final ImageEngine.Callback callback) {
        Picasso.with(context).load(url).into(new Target() {
        @Override
        public void onBitmapLoaded(Bitmap bitmap, Picasso.LoadedFrom from) {
            // mainly through the callback return Drawable object to SuperTextView
            callback.onCompleted(new BitmapDrawable(Resources.getSystem(), bitmap));
        }

        @Override
        public void onBitmapFailed(Drawable errorDrawable) {

        }

        @Override
        public void onPrepareLoad(Drawable placeHolderDrawable) {

        }
    });
  }
}
1.2.2 Install Image Engine

After implementing Engine, the next step is to install it into SuperTextView.

CoorChice it is recommended to install in the onCreate() of the application, so that when you need to use SuperTextView to load and display the net picture, you can use the three-party image load framwork.

public class STVApplication extends Application {

  @Override
  public void onCreate() {
    super.onCreate();
    // 安装图片引擎
    ImageEngine.install(new GlideEngine(this));
    // ImageEngine.install(new PicassoEngine(this));
  }
}

One line of code for easy installation.

It should be noted that at any time, the post-installed Engine instance will always replace the previously installed Engine instance, ie SuperTextView only allows one Engine instance to exist globally.

Now you can have SuperTextView load the picture using the specified three-party image load framework.

2. How to get started SuperTextView v3.0

	dependencies {
	   compile 'com.github.chenBingX:SuperTextView:v3.0.0'
	}

3. Other

  • Fix an animation problem
  • Some optimization

v2.0 - The future, from now on

All along, CoorChice has a vision and expects to be able to create such a control: it can meet most of your development needs, display text, pictures, geometry, animation, state, so that you can use a control to be efficient Complete most of the development work. It is so powerful, as if it is mentally minded, accepting your input, and presenting a stunning picture according to your mind. With the arrival of 【SuperTextView v2.0】, we are one step closer to this idea. Now, come and see 【SuperTextView v2.0】!

SuperTextView v2.0

1 Now, Picture

In 【SuperTextView v2.0】, support for image display has been added. But it's not just about displaying pictures, it's also smart to crop the image to your desired shape based on your input.

image

Add a rounded corner to the picture, add a border, or turn it directly into a circle. All you need to do is set a few simple properties that are instantly visible in front of your eyes.

1.1 Display Picture

How to use SuperTextView to display a picture?

Just add the following two lines of code to the xml.

<com.coorchice.library.SuperTextView
    ...
    app:stv_state_drawable="@drawable/avatar1"
    app:stv_drawableAsBackground="true"
    ...
 />

If you are a loyal user of SuperTextView, you will find that the original state_drawable can now be used to display a picture.

1.2 Fill the picture with rounded corners

Now that your picture is in front of you, maybe you want to do something different about it, for example, add a rounded corner, or directly become a circle? No problem, SuperTextView is now fully qualified for this kind of work.

<com.coorchice.library.SuperTextView
    android:layout_width="100dp"
    android:layout_height="100dp"
    ...
    app:stv_corner="15dp"
    app:stv_state_drawable="@drawable/avatar1"
    app:stv_drawableAsBackground="true"
    ...
 />

So Easy! On the basis of the original you only need to set a reasonable the corner.

1.3 Maybe you still want a border

Sometimes you may need to use a border to wrap your picture, as in the example above. That's right, this is definitely within the scope of the SuperTextView capability.

<com.coorchice.library.SuperTextView
    android:layout_width="100dp"
    android:layout_height="100dp"
    ...
    app:stv_corner="50dp"
    app:stv_stroke_color="#F4E187"
    app:stv_stroke_width="4dp"
    app:stv_state_drawable="@drawable/avatar1"
    app:stv_drawableAsBackground="true"
    ...
 />

app:stv_stroke_color controls the color of the border, and app:stv_stroke_width controls the width of the border. Everything is so smooth, a intelligent control should be like this, right?

2 Second StateDrawable

In the face of complex changes in demand, 【SuperTextView】gave birth to a second drawable to deal with this complexity.

state_drawable2 .

Now, CoorChice will show you how the two effects in the above picture are implemented.

  • eg. 1
<com.coorchice.library.SuperTextView
    android:layout_width="100dp"
    android:layout_height="100dp"
    ...
    app:stv_corner="50dp"
    app:stv_state_drawable="@drawable/avatar1"
    app:stv_drawableAsBackground="true"
    // The configuration of state_drawable2 starts here
    app:stv_isShowState2="true"
    app:stv_state_drawable2="@drawable/recousers"
    app:stv_state_drawable2_mode="rightTop"
    app:stv_state_drawable2_height="20dp"
    app:stv_state_drawable2_width="20dp"
    ...
 />
  • eg. 2
<com.coorchice.library.SuperTextView
    android:layout_width="100dp"
    android:layout_height="100dp"
    ...
    // background
    android:background="@drawable/avatar7"
    // The configuration of drawable1 starts here
    app:stv_isShowState="true"
    app:stv_state_drawable="@drawable/triangle"
    app:stv_state_drawable_mode="leftTop"
    app:stv_state_drawable_width="20dp"
    app:stv_state_drawable_height="20dp"
    // The configuration of state_drawable2 starts here
    app:stv_isShowState2="true"
    app:stv_state_drawable2="@drawable/recousers"
    app:stv_state_drawable2_mode="rightTop"
    app:stv_state_drawable2_height="20dp"
    app:stv_state_drawable2_width="20dp"
    ...
 />

As you are familiar with, state_drawable2 continues all the smooth operations of the first generation. Under the wise use of your smart, 【SuperTextView】 will be able to shine! 😉

3 The era of Adjuster

Previously, the design of Adjuster made 【SuperTextView】a soul and a smarter control. The insertion of the drawing process, the capture of touch events, makes it easy to change the state of a control from the outside. Creativity begins with the heart and goes here.

Now, 【SuperTextView】can carry up to 3 Adjuster at the same time! Maybe your creativity will be more dazzling.

In the above example, CoorChice adds the two early the【Sweep】and the【Move】effects to a 【SuperTextView】, and the result is what you see.

More Adjuster means more combinations and more surprises. In 【v1.4.0】, CoorChice also uses Adjuster to easily implement the press color change function.

This is the era of Adjuster, you can use it to be creative.

⚠️ Note that the original setAdjuster(Adjuster) method is still preserved, but future versions will be removed and you must migrate as soon as possible. The new alternative is addAdjuster(Adjuster).

4 Other

  • Fixed spelling of the property app:stv_shaderMode="leftToRight" that controls the Shader mode. The right isapp:stv_shaderMode="leftTopRight" . If you use this property, please correct it after upgrading 【SuperTextView v2.0】.
  • Added set/getPressBgColor() and set/getPressTextColor() to control the background color in the code.

v1.4.0

  • SuperTextView support to press to change background color and text color.

image

You just need to set these properties at the xml file like this:

# set the background color when you pressed
app:stv_pressBgColor="@color/red"
# set the text color when you pressed
app:stv_pressTextColor="@color/white"
  • There is a new method getCorners(). You can get the infomation of the corners in the SuperTextView, sometimes you really want to use this method.
  • How to use SuperTextView v1.4?
dependencies {
	compile 'com.github.chenBingX:SuperTextView:v1.4'
}

v1.3

  • Now, you can change frame rate at any time.
mSuperTextView.setFrameRate(30);
// set 30 fps
  • Optimize the animation performance.
  • Cool, Cool, Cool! Shader is coming!

link

A touch namely change, imagine can't be stop. Artist, play to your creativity!

You can set the Shader Effect in the xml, and you can。

app:stv_shaderEnable="true"
// set true to begin shader.

app:stv_shaderStartColor="@color/main_blue"
// set shader start color.

app:stv_shaderEndColor="@color/pink"
// set shader end color.

app:stv_shaderMode="rightToLeft"
// set shader mode. These are four mode:
// topTopBottom, bottomToTop, leftToRight, rightToLeft

Of course, these properties can be changed by set/get method. eg:

mSuperTextView.setShaderStartColor(Color.RED);
allprojects {
    repositories {
        ...
        maven { url 'https://jitpack.io' }
    }
}

dependencies {
    compile 'com.github.chenBingX:SuperTextView:v1.3'
}

v1.1

  • Support Android 4.0,SdkVersion 14.
  • Support elegant fascinating 【Chain Programming】 , eg:
mSuperTextView.setAdjuster(new MoveEffectAdjuster())
        .setAutoAdjust(true)
        .startAnim();
  • Reduce the library memory.

v1.0

1 Attribute

SuperTextView properties can be set in the XML easily, and you can see the effect immediately. Just like to use TextView.

<SuperTextView
    android:layout_width="50dp"
    android:layout_height="50dp"

    //Set Corner.
    //If you want to get a circle, you just need to set the value of half of width.
    app:stv_corner="25dp"
    //Corner of left-top
    app:stv_left_top_corner="true"
    //Corner of right-top
    app:stv_right_top_corner="true"
    //Corner of left-bottom
    app:stv_left_bottom_corner="true"
    //Corner of right-bottom
    app:stv_right_bottom_corner="true"
    //Fill color
    app:stv_solid="@color/red"
    //Stroke color
    app:stv_stroke_color="@color/black"
    //Stroke width
    app:stv_stroke_width="2dp"
    //Set a state drawbale
    //The default size is half of the SuperTextView.
    app:stv_state_drawable="@drawable/emoji"
    //The mode of the state drawable. Optional values:
    // left、top、right、bottom、center(Default)、
    //leftTop、rightTop、leftBottom、rightBottom、
    //fill(Fill the SuperTextView. In this case, set state drawable size will not work.)
    app:stv_state_drawable_mode="center"
    //state drawable height
    app:stv_state_drawable_height="30dp"
    //state drawable width
    app:stv_state_drawable_width="30dp"
    //The padding of the left, it base on the value of state_drawable_mode.
    app:stv_state_drawable_padding_left="10dp"
    //The padding of the top, it base on the value of state_drawable_mode.
    app:stv_state_drawable_padding_top="10dp"
    //boolean. Whether to show the state drawble.
    app:stv_isShowState="true"
    //Whether to use the Stroke Text Function.
    //Attention, Once you opne this function, setTextColor() will not work.
    //That means you must to uses text_fill_color to set text color.
    app:stv_text_stroke="true"
    // Text stroke color. The default value is Color.BLACK.
    app:stv_text_stroke_color="@color/black"
    // Stroke text width.
    app:stv_text_stroke_width="1dp"
    // Stroke text color. The default value is Color.BLACK.
    app:stv_text_fill_color="@color/blue"
    //boolean. Whether to use the Adjuster Function.
    //Use this function to do what you want to do.
    //If open this function, but you haven't implemented your Adjuster, the DefaultAdjuster will be used.
    //The DefaultAdjuster can auto adjust text size.
    app:stv_autoAdjust="true"
    />

All the attributes can be set in the java. You can also to get their value. e.g.:

mSuperTextView.setCorner(10);
mSuperTextView.getCorner();

1.1 Corner And Border

image

Usually, you have to write and manage a lot of file to implement the effect of the above chart. But now, you can easy to do this in the XML.

1.2 Not Simple Corner

image

Different from general Corner, SuperTextView can support to precise control the location of corner. One, two , three, what ever you want.

1.3 Amazing Stroke Text

Use Stroke text is so easily!

1.4 High-Efficient State Drawable

Different from general state drawable, SuperTextView supports more precise control options. You can easy to set state drawable, just to use one attribute.

2 Explosive Adjuster

Adjuster is be designed to insert some options in the drawing process of the SuperTextView. It has very important sense. e.g. The DefaultAdjuster can auto adjust text size before the text be draw. Of course, you can use it to do any thing.

If you want to use Adjuster, you must to invoke SuperTextView.setAutoAdjust(true). Of course, you can invoke SuperTextView.setAutoAdjust(false) to stop it at any time. You should invoke these method carefully. Because, once you invoke the SuperTextView.setAutoAdjust(true), but didn't set your Adjuster before, the DefaultAdjuster will be used immediately.Until you set yourself Adjuster.

2.1 Intervene Drawing

To implement a Adjuster, you need to extends SuperTextView.Adjuster,and implement adjust(SuperTextView v, Canvas canvas) method. Adjuster.adjust() will be invoke whenever the draw happened, that means you can intervene the drawing process in the outside.

public class YourAdjuster extends SuperTextView.Adjuster {

  @Override
  protected void adjust(SuperTextView v, Canvas canvas) {
    //do your business。
  }

}

Attention, if you start animation, you must be very careful to write the code in the adjuster(). Because the animation will be draw 60fps/s. That means, this method will be invoked 60 times in a second!So, do not to create any new object in this method. Otherwise, your app will be get a big lag!Because it will cause【Memory Thrashing】, and GC occur frequently. About the detail reason, you can see my this two articles:

2.2 Response Touch Event

If you override the onTouch(SuperTextView v, MotionEvent event) method of the Adjuster, you will get the touch events of the SuperTextView. It's very important to get a series of touch events of SuperTextView to handle. And you must return true in the onTouch(), Otherwise you will just get a ACTION_DOWN event, not a flow of events.

public class YourAdjuster extends SuperTextView.Adjuster {

  @Override
  protected void adjust(SuperTextView v, Canvas canvas) {
    //do your business。
  }

  @Override
  public boolean onTouch(SuperTextView v, MotionEvent event) {
    //you can get the touch event.
    //If want to get a series of touch event, you must return true here.
  }

}

2.3 So Amazing Effect

Because the SuperTextView the build-in animation driven, you can use Adjuster to implement the unbelievable effect. All the things you need to do is invoke startAnim()and stopAnim() to start or stop animation after your Adjuster write down.

As you can see, these beautiful effect is be implemented by Adjuster. This pull plugin design, makes you can use a new Adjuster in the SuperTextView at any time. You just need to create a new Adjuster, then invoke setAdjuster().

@Alex_Cin hopes to see the Ripple Effect, so in the RippleAdjuster.java, I've shown how to use Adjuster with Animation Driven to implement the Ripple Effect. 【RippleAdjuster.java link:https://github.com/chenBingX/SuperTextView/blob/master/app/src/main/java/com/coorchice/supertextview/SuperTextView/Adjuster/RippleAdjuster.java】

See, you can implement your Ripple Effect.

2.4 Set the hierarchy of Adjuster

Adjuster is sweet designed the hierarchy function. You invoke Adjuster.setOpportunity(Opportunity opportunity) to set the hierarchy of your Adjuster in the SuperTextView.

In the SuperTextView, the hierarchy is from bottom to top is divided into:Background Hierarchy、Drawable Hierarchy、Text Hierarchy. You can use Opportunity to set the hierarchy of your Adjuster to that you want layer.

public enum Opportunity {
      BEFORE_DRAWABLE, //between backgournd layer and drawable layer
      BEFORE_TEXT,     //between drawable layer and text layer
      AT_LAST          //The top layer
}

Opportunity chart.

The default value is Opportunity.BEFORE_TEXT. Like the second chart.

In fact, SuperTextView like a canvas, and you can draw your creative on it. It makes you forces on the creation, and you never need to write these useless code.

Now you can start using SuperTextView.

  • In addition, CoorChice will occasionally share dry goods on the blog platform, including Android related technology, machine learning, algorithm,new technology, And ** some insights and thoughts about personal development and improvement**. Go to CoorChice's 【Personal Homepage】 to give me a follow.
  • SuperTextView QQ Group:775951525

License

Copyright 2017 CoorChice

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Comments
  • V3.25.99 版本报错

    V3.25.99 版本报错

    java.lang.OutOfMemoryError: Failed to allocate a 1042452 byte allocation with 797076 free bytes and 778KB until OOM at dalvik.system.VMRuntime.newNonMovableArray(Native Method) at android.graphics.Bitmap.nativeCreate(Native Method) at android.graphics.Bitmap.createBitmap(Bitmap.java:812) at android.graphics.Bitmap.createBitmap(Bitmap.java:789) at android.graphics.Bitmap.createBitmap(Bitmap.java:756) at com.coorchice.library.SuperTextView.drawDrawableBackground(SuperTextView.java:662) at com.coorchice.library.SuperTextView.drawStateDrawable(SuperTextView.java:577) at com.coorchice.library.SuperTextView.onDraw(SuperTextView.java:393) at android.view.View.draw(View.java:15231) at android.view.View.updateDisplayListIfDirty(View.java:14167) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.draw(View.java:15234) at android.view.View.updateDisplayListIfDirty(View.java:14167) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at androidx.recyclerview.widget.RecyclerView.drawChild(RecyclerView.java:4820) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.draw(View.java:15234) at androidx.recyclerview.widget.RecyclerView.draw(RecyclerView.java:4219) at android.view.View.updateDisplayListIfDirty(View.java:14167) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.updateDisplayListIfDirty(View.java:14162) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.draw(View.java:15234) at android.widget.FrameLayout.draw(FrameLayout.java:598) at androidx.core.widget.NestedScrollView.draw(NestedScrollView.java:1931) at android.view.View.updateDisplayListIfDirty(View.java:14167) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.draw(View.java:15234) at androidx.viewpager.widget.ViewPager.draw(ViewPager.java:2426) at android.view.View.updateDisplayListIfDirty(View.java:14167) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.draw(View.java:15234) at android.view.View.updateDisplayListIfDirty(View.java:14167) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.draw(View.java:15234) at androidx.viewpager.widget.ViewPager.draw(ViewPager.java:2426) at android.view.View.updateDisplayListIfDirty(View.java:14167) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.updateDisplayListIfDirty(View.java:14162) at android.view.View.getDisplayList(View.java:14189) at android.view.View.draw(View.java:14959) at android.view.ViewGroup.drawChild(ViewGroup.java:3429) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3222) at android.view.View.updateDisplayListIfDirty(View.java:14162) at android.view.View.getD

    上面是报错信息

    下面是代码具体使用 <com.coorchice.library.SuperTextView android:id="@+id/tab_others_explosion_rv_image" android:layout_width="match_parent" android:layout_height="@dimen/px310" app:stv_corner="@dimen/px30" app:stv_right_top_corner="true" app:stv_left_top_corner="true" android:layout_centerHorizontal="true" app:stv_state_drawable="@mipmap/icon_bag" app:stv_drawableAsBackground="true"/>

    ###报错场景 在recyclerview中使用SuperTextView(加载item圆角图片) 图片数量过多 就会报上面的错误 使用Imageview则不会

    opened by Hn1993 4
  • 动态设置 text有时会不显示问题(小米机型出现,华为手机未出现)

    动态设置 text有时会不显示问题(小米机型出现,华为手机未出现)

    if ("已预约".equals(text) || "服务次数已用完".equals(text)) { mServiceDetailAppointmentStv.setTextColor(getContext().getResources().getColor(R.color.colorSubhead)); mServiceDetailAppointmentStv.setStrokeColor(getContext().getResources().getColor(R.color.colorSubhead)); mServiceDetailAppointmentStv.setText(text);

    颜色设置生效,text设置不显示, 机型:android9.0+小米mix2s+MIUI10稳定版 出现文字不显示问题 华为荣耀8X android8.0 没有出现过这样的问题 使用版本为 api 'com.github.chenBingX:SuperTextView:v3.1.1'

    opened by xyZangGit 4
  •  3.1.1 依赖冲突

    3.1.1 依赖冲突

    AGPBI: {"kind":"error","text":"Program type already present: com.coorchice.library.BuildConfig","sources":[{}],"tool":"D8"}

    3.1.1报这个 3.0.0正常使用 没发现是哪个依赖冲突了

    opened by liaoshengrui 3
  • 我引用了一个视图框架,再集成就成这个样子了

    我引用了一个视图框架,再集成就成这个样子了

    \app\build\intermediates\res\merged\debug\values\values.xml Error:(439) Attribute "stroke_width" already defined with incompatible format. Error:(425) Original attribute defined here. Error:(439) Attribute "stroke_width" already defined with incompatible format. Error:(425) Original attribute defined here.

    opened by YxmCute 3
  • 3.2.5 stv_state_drawable 页面加载的时候就报错

    3.2.5 stv_state_drawable 页面加载的时候就报错

    dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.sj.shijie-ZyBYiMLhaumfKW_Hw-7IdQ==/base.apk"],nativeLibraryDirectories=[/data/app/com.sj.shijie-ZyBYiMLhaumfKW_Hw-7IdQ==/lib/arm64, /data/app/com.sj.shijie-ZyBYiMLhaumfKW_Hw-7IdQ==/base.apk!/lib/arm64-v8a, /system/lib64]]] couldn't find "libGifLib.so"

    报这个错,我把版本切换到3.1.5就没问题了

    opened by SemiraChen 2
  • 打包运行报错

    打包运行报错

    版本:implementation 'com.github.chenBingX:SuperTextView:v3.2.5.99'

    调试debug都没问题,但是打包运行直接就奔溃了,加载界面xml就报错

    2020-12-02 18:11:40.238 22069-22069/? E/Tag: Class load success! 2020-12-02 18:11:40.238 22069-22069/? E/zygote: ----- class 'Lcom/coorchice/library/gifdecoder/JNI;' cl=0x13a40230 ----- 2020-12-02 18:11:40.238 22069-22069/? E/zygote: objectSize=172 (172 from super) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: access=0x0008.0001 2020-12-02 18:11:40.238 22069-22069/? E/zygote: super='java.lang.Class<java.lang.Object>' (cl=0x0) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: vtable (0 entries, 11 in super): 2020-12-02 18:11:40.238 22069-22069/? E/zygote: direct methods (10 entries): 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 0: void com.coorchice.library.gifdecoder.JNI.() 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 1: boolean com.coorchice.library.gifdecoder.JNI.bytesIsGif(byte[]) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 2: long com.coorchice.library.gifdecoder.JNI.copy(long) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 3: void com.coorchice.library.gifdecoder.JNI.copyDestroy(long) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 4: void com.coorchice.library.gifdecoder.JNI.destroy(long) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 5: int com.coorchice.library.gifdecoder.JNI.getHeight(long) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 6: int com.coorchice.library.gifdecoder.JNI.getWidth(long) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 7: void com.coorchice.library.gifdecoder.JNI.gotoFrame(long, int, android.graphics.Bitmap) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 8: long com.coorchice.library.gifdecoder.JNI.openBytes(byte[]) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: 9: int com.coorchice.library.gifdecoder.JNI.updateFrame(long, android.graphics.Bitmap) 2020-12-02 18:11:40.238 22069-22069/? E/zygote: Failed to register native method com.coorchice.library.gifdecoder.JNI.openFile(Ljava/lang/String;)J in /data/app/com.rzt.newborn-SH_o0kO_Fo8rX4hWlQho3w==/base.apk 2020-12-02 18:11:40.239 22069-22069/? E/AndroidRuntime: FATAL EXCEPTION: main Process: com.rzt.newborn, PID: 22069 java.lang.RuntimeException: Unable to start activity ComponentInfo{com.rzt.newborn/com.rzt.newborn.activity.SettingServerActivity}: android.view.InflateException: Binary XML file line #9: Binary XML file line #9: Error inflating class com.coorchice.library.SuperTextView at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2983) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3061) at android.app.ActivityThread.-wrap12(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1747) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:192) at android.app.ActivityThread.main(ActivityThread.java:6842) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:886) Caused by: android.view.InflateException: Binary XML file line #9: Binary XML file line #9: Error inflating class com.coorchice.library.SuperTextView Caused by: android.view.InflateException: Binary XML file line #9: Error inflating class com.coorchice.library.SuperTextView Caused by: java.lang.reflect.InvocationTargetException at java.lang.reflect.Constructor.newInstance0(Native Method) at java.lang.reflect.Constructor.newInstance(Constructor.java:334) at android.view.LayoutInflater.createView(LayoutInflater.java:647) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:790) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:730) at android.view.LayoutInflater.rInflate(LayoutInflater.java:863) at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:824) at android.view.LayoutInflater.inflate(LayoutInflater.java:515) at android.view.LayoutInflater.inflate(LayoutInflater.java:423) at android.view.LayoutInflater.inflate(LayoutInflater.java:374) at androidx.appcompat.app.AppCompatDelegateImpl.c(AppCompatDelegateImpl.java:9) at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:1) at com.rzt.newborn.base.SuperActivity.setContentView(SuperActivity.java:1) at com.rzt.newborn.base.SuperActivity.onCreate(SuperActivity.java:2) at android.app.Activity.performCreate(Activity.java:7066) at android.app.Activity.performCreate(Activity.java:7057) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1216) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2931) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3061) at android.app.ActivityThread.-wrap12(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1747) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:192) at android.app.ActivityThread.main(ActivityThread.java:6842) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:886) Caused by: java.lang.NoSuchMethodError: no static or non-static method "Lcom/coorchice/library/gifdecoder/JNI;.openFile(Ljava/lang/String;)J" at java.lang.Runtime.nativeLoad(Native Method) at java.lang.Runtime.doLoad(Runtime.java:1099) at java.lang.Runtime.loadLibrary0(Runtime.java:1014) at java.lang.System.loadLibrary(System.java:1657) at com.coorchice.library.gifdecoder.JNI.(JNI.java:1) at com.coorchice.library.gifdecoder.JNI.bytesIsGif(Native Method) at e.b.a.b.c.a(GifDecoder.java:21) at com.coorchice.library.SuperTextView.b(SuperTextView.java:156) at com.coorchice.library.SuperTextView.b(SuperTextView.java:22) at com.coorchice.library.SuperTextView.a(SuperTextView.java:4) at com.coorchice.library.SuperTextView.(SuperTextView.java:48) at java.lang.reflect.Constructor.newInstance0(Native Method)  at java.lang.reflect.Constructor.newInstance(Constructor.java:334)  at android.view.LayoutInflater.createView(LayoutInflater.java:647)  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:790)  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:730)  at android.view.LayoutInflater.rInflate(LayoutInflater.java:863)  at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:824)  at android.view.LayoutInflater.inflate(LayoutInflater.java:515)  at android.view.LayoutInflater.inflate(LayoutInflater.java:423)  at android.view.LayoutInflater.inflate(LayoutInflater.java:374)  at androidx.appcompat.app.AppCompatDelegateImpl.c(AppCompatDelegateImpl.java:9)  at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:1)  at com.rzt.newborn.base.SuperActivity.setContentView(SuperActivity.java:1)  at com.rzt.newborn.base.SuperActivity.onCreate(SuperActivity.java:2)  at android.app.Activity.performCreate(Activity.java:7066)  at android.app.Activity.performCreate(Activity.java:7057)  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1216)  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2931)  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3061)  at android.app.ActivityThread.-wrap12(Unknown Source:0)  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1747)  at android.os.Handler.dispatchMessage(Handler.java:106)  at android.os.Looper.loop(Looper.java:192)  at android.app.ActivityThread.main(ActivityThread.java:6842)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:886)  2020-12-02 18:11:40.244 22069-22069/? W/System.err: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.rzt.newborn/com.rzt.newborn.activity.SettingServerActivity}: android.view.InflateException: Binary XML file line #9: Binary XML file line #9: Error inflating class com.coorchice.library.SuperTextView 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2983) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3061) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.app.ActivityThread.-wrap12(Unknown Source:0) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1747) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.os.Handler.dispatchMessage(Handler.java:106) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.os.Looper.loop(Looper.java:192) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.app.ActivityThread.main(ActivityThread.java:6842) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at java.lang.reflect.Method.invoke(Native Method) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:886) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: Caused by: android.view.InflateException: Binary XML file line #9: Binary XML file line #9: Error inflating class com.coorchice.library.SuperTextView 2020-12-02 18:11:40.244 22069-22069/? W/System.err: Caused by: android.view.InflateException: Binary XML file line #9: Error inflating class com.coorchice.library.SuperTextView 2020-12-02 18:11:40.244 22069-22069/? W/System.err: Caused by: java.lang.reflect.InvocationTargetException 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at java.lang.reflect.Constructor.newInstance0(Native Method) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at java.lang.reflect.Constructor.newInstance(Constructor.java:334) 2020-12-02 18:11:40.244 22069-22069/? W/System.err: at android.view.LayoutInflater.createView(LayoutInflater.java:647) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:790) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:730) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.view.LayoutInflater.rInflate(LayoutInflater.java:863) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:824) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.view.LayoutInflater.inflate(LayoutInflater.java:515) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.view.LayoutInflater.inflate(LayoutInflater.java:423) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.view.LayoutInflater.inflate(LayoutInflater.java:374) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at androidx.appcompat.app.AppCompatDelegateImpl.c(AppCompatDelegateImpl.java:9) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:1) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.rzt.newborn.base.SuperActivity.setContentView(SuperActivity.java:1) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.rzt.newborn.base.SuperActivity.onCreate(SuperActivity.java:2) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.Activity.performCreate(Activity.java:7066) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.Activity.performCreate(Activity.java:7057) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1216) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2931) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3061) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.ActivityThread.-wrap12(Unknown Source:0) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1747) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.os.Handler.dispatchMessage(Handler.java:106) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.os.Looper.loop(Looper.java:192) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at android.app.ActivityThread.main(ActivityThread.java:6842) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at java.lang.reflect.Method.invoke(Native Method) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:886) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: Caused by: java.lang.NoSuchMethodError: no static or non-static method "Lcom/coorchice/library/gifdecoder/JNI;.openFile(Ljava/lang/String;)J" 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at java.lang.Runtime.nativeLoad(Native Method) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at java.lang.Runtime.doLoad(Runtime.java:1099) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at java.lang.Runtime.loadLibrary0(Runtime.java:1014) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at java.lang.System.loadLibrary(System.java:1657) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.coorchice.library.gifdecoder.JNI.(JNI.java:1) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.coorchice.library.gifdecoder.JNI.bytesIsGif(Native Method) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at e.b.a.b.c.a(GifDecoder.java:21) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.coorchice.library.SuperTextView.b(SuperTextView.java:156) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.coorchice.library.SuperTextView.b(SuperTextView.java:22) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.coorchice.library.SuperTextView.a(SuperTextView.java:4) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: at com.coorchice.library.SuperTextView.(SuperTextView.java:48) 2020-12-02 18:11:40.245 22069-22069/? W/System.err: ... 27 more

    opened by Zvirtuey 1
  • 2020 3/12 日最新版本demo gif演示页面闪退

    2020 3/12 日最新版本demo gif演示页面闪退

    hi,手机小米4,android 6.0进入gif页面经常闪退

    Process: com.coorchice.supertextview, PID: 26735 java.lang.RuntimeException: Unable to start activity ComponentInfo{com.coorchice.supertextview/com.coorchice.supertextview.GifListActivity}: android.view.InflateException: Binary XML file line #203: Binary XML file line #203: Error inflating class at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2483) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2543) at android.app.ActivityThread.access$1000(ActivityThread.java:156) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1407) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:157) at android.app.ActivityThread.main(ActivityThread.java:5653) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:746) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636) Caused by: android.view.InflateException: Binary XML file line #203: Binary XML file line #203: Error inflating class at android.view.LayoutInflater.inflate(LayoutInflater.java:543) at android.view.LayoutInflater.inflate(LayoutInflater.java:427) at android.view.LayoutInflater.inflate(LayoutInflater.java:374) at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393) at android.app.Activity.setContentView(Activity.java:2237) at com.coorchice.supertextview.GifListActivity.onCreate(GifListActivity.java:27) at android.app.Activity.performCreate(Activity.java:6362) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2436) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2543)  at android.app.ActivityThread.access$1000(ActivityThread.java:156)  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1407)  at android.os.Handler.dispatchMessage(Handler.java:102)  at android.os.Looper.loop(Looper.java:157)  at android.app.ActivityThread.main(ActivityThread.java:5653)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:746)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636)  Caused by: android.view.InflateException: Binary XML file line #203: Error inflating class at android.view.LayoutInflater.createView(LayoutInflater.java:649) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:768) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:708) at android.view.LayoutInflater.rInflate(LayoutInflater.java:839) at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802) at android.view.LayoutInflater.rInflate(LayoutInflater.java:842) at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802) at android.view.LayoutInflater.inflate(LayoutInflater.java:519) at android.view.LayoutInflater.inflate(LayoutInflater.java:427)  at android.view.LayoutInflater.inflate(LayoutInflater.java:374)  at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)  at android.app.Activity.setContentView(Activity.java:2237)  at com.coorchice.supertextview.GifListActivity.onCreate(GifListActivity.java:27)  at android.app.Activity.performCreate(Activity.java:6362)  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108)  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2436)  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2543)  at android.app.ActivityThread.access$1000(ActivityThread.java:156)  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1407)  at android.os.Handler.dispatchMessage(Handler.java:102)  at android.os.Looper.loop(Looper.java:157)  at android.app.ActivityThread.main(ActivityThread.java:5653)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:746)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636)  Caused by: java.lang.reflect.InvocationTargetException at java.lang.reflect.Constructor.newInstance(Native Method) at android.view.LayoutInflater.createView(LayoutInflater.java:623) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:768)  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:708)  at android.view.LayoutInflater.rInflate(LayoutInflater.java:839)  at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802)  at android.view.LayoutInflater.rInflate(LayoutInflater.java:842)  at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802)  at android.view.LayoutInflater.inflate(LayoutInflater.java:519)  at android.view.LayoutInflater.inflate(LayoutInflater.java:427)  at android.view.LayoutInflater.inflate(LayoutInflater.java:374)  at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)  at android.app.Activity.setContentView(Activity.java:2237)  at com.coorchice.supertextview.GifListActivity.onCreate(GifListActivity.java:27)  at android.app.Activity.performCreate(Activity.java:6362)  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108)  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2436)  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2543)  at android.app.ActivityThread.access$1000(ActivityThread.java:156)  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1407)  at android.os.Handler.dispatchMessage(Handler.java:102)  at android.os.Looper.loop(Looper.java:157)  at android.app.ActivityThread.main(ActivityThread.java:5653)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:746)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636)  Caused by: java.lang.OutOfMemoryError: Failed to allocate a 1904412 byte allocation with 727456 free bytes and 710KB until OOM at dalvik.system.VMRuntime.newNonMovableArray(Native Method) at android.graphics.Bitmap.nativeCreate(Native Method) at android.graphics.Bitmap.createBitmap(Bitmap.java:843) at android.graphics.Bitmap.createBitmap(Bitmap.java:820) at android.graphics.Bitmap.createBitmap(Bitmap.java:787) at com.coorchice.library.gifdecoder.GifDecoder.init(GifDecoder.java:128) at com.coorchice.library.gifdecoder.GifDecoder.(GifDecoder.java:121) at com.coorchice.library.gifdecoder.GifDecoder.copy(GifDecoder.java:90) at com.coorchice.library.gifdecoder.GifDrawable.copy(GifDrawable.java:77) at com.coorchice.library.gifdecoder.GifCache.fromResource(GifCache.java:171) at com.coorchice.library.SuperTextView.innerSetDrawable2(SuperTextView.java:1520) at com.coorchice.library.SuperTextView.initAttrs(SuperTextView.java:286) at com.coorchice.library.SuperTextView.init(SuperTextView.java:225) at com.coorchice.library.SuperTextView.(SuperTextView.java:194) at java.lang.reflect.Constructor.newInstance(Native Method)  at android.view.LayoutInflater.createView(LayoutInflater.java:623)  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:768)  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:708)  at android.view.LayoutInflater.rInflate(LayoutInflater.java:839)  at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802)  at android.view.LayoutInflater.rInflate(LayoutInflater.java:842)  at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802)  at android.view.LayoutInflater.inflate(LayoutInflater.java:519)  at android.view.LayoutInflater.inflate(LayoutInflater.java:427)  at android.view.LayoutInflater.inflate(LayoutInflater.java:374)  at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)  at android.app.Activity.setContentView(Activity.java:2237)  at com.coorchice.supertextview.GifListActivity.onCreate(GifListActivity.java:27)  at android.app.Activity.performCreate(Activity.java:6362)  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108)  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2436)  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2543)  at android.app.ActivityThread.access$1000(ActivityThread.java:156)  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1407)  at android.os.Handler.dispatchMessage(Handler.java:102)  at android.os.Looper.loop(Looper.java:157)  at android.app.ActivityThread.main(ActivityThread.java:5653)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:746)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636) 

    opened by xumengyin 1
  • RecyclerView中无法使用状态图

    RecyclerView中无法使用状态图

    在列表的item中使用SuperTextView作为根布局,加载失败,添加父布局之后依然无法生成,后来测试是因为使用了状态图导致无法实例化该控件。详情见日志:

    android.view.InflateException: Binary XML file line #7: Binary XML file line #7: Error inflating class <unknown>
        Caused by: android.view.InflateException: Binary XML file line #7: Error inflating class <unknown>
        Caused by: java.lang.reflect.InvocationTargetException
            at java.lang.reflect.Constructor.newInstance0(Native Method)
            at java.lang.reflect.Constructor.newInstance(Constructor.java:334)
            at android.view.LayoutInflater.createView(LayoutInflater.java:651)
            at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:794)
            at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:734)
            at android.view.LayoutInflater.rInflate(LayoutInflater.java:867)
            at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:828)
            at android.view.LayoutInflater.inflate(LayoutInflater.java:519)
            at android.view.LayoutInflater.inflate(LayoutInflater.java:427)
            at com.chad.library.adapter.base.util.AdapterUtilsKt.getItemView(AdapterUtils.kt:15)
            at com.chad.library.adapter.base.BaseQuickAdapter.createBaseViewHolder(BaseQuickAdapter.kt:584)
            at com.chad.library.adapter.base.BaseQuickAdapter.onCreateDefViewHolder(BaseQuickAdapter.kt:580)
            at com.chad.library.adapter.base.BaseQuickAdapter.onCreateViewHolder(BaseQuickAdapter.kt:249)
            at com.chad.library.adapter.base.BaseQuickAdapter.onCreateViewHolder(BaseQuickAdapter.kt:74)
            at androidx.recyclerview.widget.RecyclerView$Adapter.createViewHolder(RecyclerView.java:6949)
            at androidx.recyclerview.widget.RecyclerView$Recycler.tryGetViewHolderForPositionByDeadline(RecyclerView.java:6118)
            at androidx.recyclerview.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:6001)
            at androidx.recyclerview.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:5997)
            at androidx.recyclerview.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:2227)
            at androidx.recyclerview.widget.GridLayoutManager.layoutChunk(GridLayoutManager.java:563)
            at androidx.recyclerview.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1518)
            at androidx.recyclerview.widget.LinearLayoutManager.onLayoutChildren(LinearLayoutManager.java:613)
            at androidx.recyclerview.widget.GridLayoutManager.onLayoutChildren(GridLayoutManager.java:172)
            at androidx.recyclerview.widget.RecyclerView.dispatchLayoutStep2(RecyclerView.java:4032)
            at androidx.recyclerview.widget.RecyclerView.onMeasure(RecyclerView.java:3444)
            at android.view.View.measure(View.java:22024)
            at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6584)
            at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1514)
            at android.widget.LinearLayout.measureVertical(LinearLayout.java:806)
            at android.widget.LinearLayout.onMeasure(LinearLayout.java:685)
            at android.view.View.measure(View.java:22024)
            at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6584)
            at android.widget.FrameLayout.onMeasure(FrameLayout.java:185)
            at android.view.View.measure(View.java:22024)
            at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6584)
            at android.widget.FrameLayout.onMeasure(FrameLayout.java:185)
            at android.view.View.measure(View.java:22024)
            at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6584)
            at android.widget.FrameLayout.onMeasure(FrameLayout.java:185)
            at com.android.internal.policy.DecorView.onMeasure(DecorView.java:724)
            at android.view.View.measure(View.java:22024)
            at android.view.ViewRootImpl.performMeasure(ViewRootImpl.java:2446)
            at android.view.ViewRootImpl.measureHierarchy(ViewRootImpl.java:1534)
            at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1787)
            at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1422)
            at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6834)
            at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1029)
            at android.view.Choreographer.doCallbacks(Choreographer.java:841)
    2020-02-21 17:52:48.914 16524-16524/com.cn.dcjt.firelibrary E/AndroidRuntime:     at android.view.Choreographer.doFrame(Choreographer.java:772)
            at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1015)
            at android.os.Handler.handleCallback(Handler.java:793)
            at android.os.Handler.dispatchMessage(Handler.java:98)
            at android.os.Looper.loop(Looper.java:173)
            at android.app.ActivityThread.main(ActivityThread.java:6698)
            at java.lang.reflect.Method.invoke(Native Method)
            at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
            at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:782)
         Caused by: java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.cn.dcjt.firelibrary-GMBV6WUgZG3rQ0z4EzLmHQ==/base.apk"],nativeLibraryDirectories=[/data/app/com.cn.dcjt.firelibrary-GMBV6WUgZG3rQ0z4EzLmHQ==/lib/arm64, /data/app/com.cn.dcjt.firelibrary-GMBV6WUgZG3rQ0z4EzLmHQ==/base.apk!/lib/arm64-v8a, /system/lib64, /system/vendor/lib64]]] couldn't find "libGifLib.so"
            at java.lang.Runtime.loadLibrary0(Runtime.java:1011)
            at java.lang.System.loadLibrary(System.java:1657)
            at com.coorchice.library.gifdecoder.JNI.<clinit>(JNI.java:30)
            at com.coorchice.library.gifdecoder.JNI.bytesIsGif(Native Method)
            at com.coorchice.library.gifdecoder.GifDecoder.isGif(GifDecoder.java:444)
            at com.coorchice.library.SuperTextView.innerSetDrawable(SuperTextView.java:1481)
            at com.coorchice.library.SuperTextView.initAttrs(SuperTextView.java:257)
            at com.coorchice.library.SuperTextView.init(SuperTextView.java:225)
            at com.coorchice.library.SuperTextView.<init>(SuperTextView.java:194)
            	... 57 more
    

    布局:

    <?xml version="1.0" encoding="utf-8"?>
    <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:app="http://schemas.android.com/apk/res-auto"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content">
    
        <com.coorchice.library.SuperTextView
            android:id="@+id/root_view"
            android:layout_width="120dp"
            android:layout_height="wrap_content"
            android:padding="6dp"
            app:stv_corner="3dp"
            app:stv_stroke_width="1dp"
            app:stv_stroke_color="@color/gray_ccc"
            app:stv_isShowState="true"
            app:stv_state_drawable="@drawable/ic_item_selected"
            app:stv_state_drawable_height="20dp"
            app:stv_state_drawable_mode="left"
            app:stv_state_drawable_padding_left="10dp"
            app:stv_state_drawable_width="20dp"
            android:gravity="center"
            android:text="测试内容"
            android:textSize="12sp"
            android:textColor="#046DF0"/>
    
    
    
    </RelativeLayout>
    
    opened by Vicent9920 1
  • 动态创建drawable不可见

    动态创建drawable不可见

    你好, 首先要感谢你开源提供这个库给我们用, 节省了我们大量的时间. 今天我在尝试动态创建这个view添加到布局时发现: drawable会不显示. debug跟进源码中它确实是执行了drawable.draw(canvas);

    我这边创建的代码如下, 如果我使用过程中有错或遗漏的还请指出 谢谢~ image

    opened by liangrk 0
  • 加载本地图片报错

    加载本地图片报错

    android.view.InflateException: Binary XML file line #33 in com.example.yumeishi:layout/fragment_mine: Binary XML file line #33 in com.example.yumeishi:layout/fragment_mine: Error inflating class com.coorchice.library.SuperTextView Caused by: android.view.InflateException: Binary XML file line #33 in com.example.yumeishi:layout/fragment_mine: Error inflating class com.coorchice.library.SuperTextView 设备:Android studio 模拟器 pixel 4 xl API 31 compileSdk 32

    opened by yuandoudou928 0
Releases(v3.2.6.99)
  • v3.2.6.99(Jan 17, 2022)

    • Support for setting 'Network Image' in XML for StateDrawable and StateDrawable2

    In XML, use a 'Network Image' as a background image

    <com.coorchice.library.SuperTextView
      android:id="@+id/stv_40"
      android:layout_width="150dp"
      android:layout_height="150dp"
      android:layout_gravity="center_horizontal"
      android:layout_marginTop="16dp"
      android:gravity="bottom|center"
      android:paddingBottom="1dp"
      android:text="网络背景图"
      android:textColor="#000"
      android:textSize="14sp"
      app:stv_corner="10dp"
      app:stv_isShowState="true"
      app:stv_drawableAsBackground="true"
      app:stv_solid="#f1f1f1"
      app:stv_state_drawable="https://gw.alicdn.com/imgextra/i3/O1CN01suhAFr1cXQX49D2xp_!!6000000003610-0-tps-468-466.jpg" />
    

    In XML, set the 'Network Image' for StateDrawable2

    <com.coorchice.library.SuperTextView
      android:id="@+id/stv_41"
      android:layout_width="350dp"
      android:layout_height="100dp"
      android:layout_gravity="center_horizontal"
      android:layout_marginTop="30dp"
      android:paddingLeft="116dp"
      android:paddingTop="30dp"
      android:text="StateDrawable2 网络图"
      android:textColor="@color/black"
      android:textSize="14sp"
      app:stv_corner="50dp"
      app:stv_isShowState2="true"
      app:stv_left_bottom_corner="true"
      app:stv_left_top_corner="true"
      app:stv_solid="#f1f1f1"
      app:stv_state_drawable2="https://gw.alicdn.com/imgextra/i3/O1CN01XPmcmt1vJfKcQ8o6O_!!6000000006152-0-tps-500-500.jpg"
      app:stv_state_drawable2_height="100dp"
      app:stv_state_drawable2_mode="left"
      app:stv_state_drawable2_width="100dp"/>
    
    Source code(tar.gz)
    Source code(zip)
  • v3.2.6.64(Jan 17, 2022)

    • Support for setting 'Network Image' in XML for StateDrawable and StateDrawable2

    In XML, use a 'Network Image' as a background image

    <com.coorchice.library.SuperTextView
      android:id="@+id/stv_40"
      android:layout_width="150dp"
      android:layout_height="150dp"
      android:layout_gravity="center_horizontal"
      android:layout_marginTop="16dp"
      android:gravity="bottom|center"
      android:paddingBottom="1dp"
      android:text="网络背景图"
      android:textColor="#000"
      android:textSize="14sp"
      app:stv_corner="10dp"
      app:stv_isShowState="true"
      app:stv_drawableAsBackground="true"
      app:stv_solid="#f1f1f1"
      app:stv_state_drawable="https://gw.alicdn.com/imgextra/i3/O1CN01suhAFr1cXQX49D2xp_!!6000000003610-0-tps-468-466.jpg" />
    

    In XML, set the 'Network Image' for StateDrawable2

    <com.coorchice.library.SuperTextView
      android:id="@+id/stv_41"
      android:layout_width="350dp"
      android:layout_height="100dp"
      android:layout_gravity="center_horizontal"
      android:layout_marginTop="30dp"
      android:paddingLeft="116dp"
      android:paddingTop="30dp"
      android:text="StateDrawable2 网络图"
      android:textColor="@color/black"
      android:textSize="14sp"
      app:stv_corner="50dp"
      app:stv_isShowState2="true"
      app:stv_left_bottom_corner="true"
      app:stv_left_top_corner="true"
      app:stv_solid="#f1f1f1"
      app:stv_state_drawable2="https://gw.alicdn.com/imgextra/i3/O1CN01XPmcmt1vJfKcQ8o6O_!!6000000006152-0-tps-500-500.jpg"
      app:stv_state_drawable2_height="100dp"
      app:stv_state_drawable2_mode="left"
      app:stv_state_drawable2_width="100dp"/>
    
    Source code(tar.gz)
    Source code(zip)
  • v3.2.6(Jan 17, 2022)

    • Support for setting 'Network Image' in XML for StateDrawable and StateDrawable2

    In XML, use a 'Network Image' as a background image

    <com.coorchice.library.SuperTextView
      android:id="@+id/stv_40"
      android:layout_width="150dp"
      android:layout_height="150dp"
      android:layout_gravity="center_horizontal"
      android:layout_marginTop="16dp"
      android:gravity="bottom|center"
      android:paddingBottom="1dp"
      android:text="网络背景图"
      android:textColor="#000"
      android:textSize="14sp"
      app:stv_corner="10dp"
      app:stv_isShowState="true"
      app:stv_drawableAsBackground="true"
      app:stv_solid="#f1f1f1"
      app:stv_state_drawable="https://gw.alicdn.com/imgextra/i3/O1CN01suhAFr1cXQX49D2xp_!!6000000003610-0-tps-468-466.jpg" />
    

    In XML, set the 'Network Image' for StateDrawable2

    <com.coorchice.library.SuperTextView
      android:id="@+id/stv_41"
      android:layout_width="350dp"
      android:layout_height="100dp"
      android:layout_gravity="center_horizontal"
      android:layout_marginTop="30dp"
      android:paddingLeft="116dp"
      android:paddingTop="30dp"
      android:text="StateDrawable2 网络图"
      android:textColor="@color/black"
      android:textSize="14sp"
      app:stv_corner="50dp"
      app:stv_isShowState2="true"
      app:stv_left_bottom_corner="true"
      app:stv_left_top_corner="true"
      app:stv_solid="#f1f1f1"
      app:stv_state_drawable2="https://gw.alicdn.com/imgextra/i3/O1CN01XPmcmt1vJfKcQ8o6O_!!6000000006152-0-tps-500-500.jpg"
      app:stv_state_drawable2_height="100dp"
      app:stv_state_drawable2_mode="left"
      app:stv_state_drawable2_width="100dp"/>
    
    Source code(tar.gz)
    Source code(zip)
  • v3.2.5.99(Nov 14, 2019)

    【support】 armeabi-v7a、arm64-v8a、x86

    1.【fix】setDrawablePaddingLeft() not work 2. 【OP】Clear log 3. 【Fix】SuperTextView will not draw when width or height is 0 4. 【New】Support cache gif by the GifCache 5. 【OP】Optimize Gif rendering efficiency

    Source code(tar.gz)
    Source code(zip)
  • v3.2.5.64(Nov 13, 2019)

    【support】 armeabi-v7a、arm64-v8a

    1.【fix】setDrawablePaddingLeft() not work 2. 【OP】Clear log 3. 【Fix】SuperTextView will not draw when width or height is 0 4. 【New】Support cache gif by the GifCache 5. 【OP】Optimize Gif rendering efficiency

    Source code(tar.gz)
    Source code(zip)
  • v3.2.5(Nov 13, 2019)

    【support】 armeabi-va

    1.【fix】setDrawablePaddingLeft() not work 2. 【OP】Clear log 3. 【Fix】SuperTextView will not draw when width or height is 0 4. 【New】Support cache gif by the GifCache 5. 【OP】Optimize Gif rendering efficiency

    Source code(tar.gz)
    Source code(zip)
  • v3.2.4.64(Oct 18, 2019)

    该版本仅包含了 armeabi-v7a、arm64-v8a 的 .so 库

    • 修复Drawable直接写16进制颜色值,不显示的问题
    • Drawable 支持指定层级
    • 修复 Drawable1 作为背景图时,缩放模式 scaleType 切换失效问题
    Source code(tar.gz)
    Source code(zip)
  • v3.2.4(Oct 18, 2019)

    该版本仅包含 armeabi-v7a 的 .so 库!

    • 修复Drawable直接写16进制颜色值,不显示的问题
    • Drawable 支持指定层级
    • 修复 Drawable1 作为背景图时,缩放模式 scaleType 切换失效问题
    Source code(tar.gz)
    Source code(zip)
  • v3.2.3.64(Oct 17, 2019)

  • v3.2.3(Sep 27, 2019)

  • v3.2.2(Sep 27, 2019)

  • v3.2.1(Sep 15, 2019)

    大有可为,SuperTextView(v3.2.1)

    Hi,开发者,来见识一下全新的 SuperTextView 吧!

    ||||| |:---:|:---:|:---:|:---:| |||||

    💡以上演示,均由 SuperTextView 提供强力驱动支持。

    SuperTextView 的与众不同在于,它只是一个简单的控件元素,但却不仅仅是一个控件。它生而灵动多变,强大的内嵌逻辑,为你持续提供丰富多彩却异常简单的开发支持。

    SuperTextView 将你从复杂的渲染逻辑中解救出来,一行简单的 API 接口调用,炫目的渲染效果即刻呈现。

    你只需享受自己所编写出的惊人视效,剩下的一切就放心交给 SuperTextView

    在全新的 v3.2.1 版本中,SuperTextView 再一次重新定义了自己。开发者,来看看精心为你准备的惊喜吧!🎉🎉🎉

    这是... Gif ?

    这一次,SuperTextView 为开发者带来了强力的 Gif 驱动支持。

    如果在过去,你曾经为如何在 Android 平台上展示一张 Gif 图而苦恼多日,或是困于一些三方 Gif 库的性能深渊中迷失方向。那么现在,SuperTextView 将彻底改变这一现状。

    Gif 图与 SuperTextView 生而浑然天成,因此,你可以通过最熟悉的、最自然的方式来让一张 Gif 图获得展示。就像你过去展示一张普通图片那样简单。

    得益于 c/c++ 的超高性能,以及对内存的精确操作。SuperTextView 通过使用 c/c++ 为移动平台专门定制了性能强悍的 Gif 驱动引擎。

    SuperTextViewGif 引擎,能够精确操作图像像素内存,在 Gif 图像的帧刷新时,只对局部像素内存进行更新,这让 Gif 图像渲染效率得到了质的飞跃。

    通过异步离屏渲染及多缓冲技术,使得 SuperTextView 即使在流畅展示超大 Gif 图像的时候,依旧能够保持应用界面丝滑的流畅度,以及灵敏的响应速度。

    💡以上 Demo 中,使用 SuperTextView 展示了一张 近17M 大小,包含有 265 帧图像的 Gif 图,用户界面依旧无比流畅。

    展示 Gif 超简单!

    SuperTextView 中展示一张 Gif 图,超简单!

    你可以直接 XML 布局文档中配置,或者在代码中进行添加。

    XML 中配置 Gif

    <com.coorchice.library.SuperTextView
        android:id="@+id/stv_1"
        android:layout_width="match_parent"
        android:layout_height="150dp"
    
        // 配置 Gif
        app:stv_state_drawable="@drawable/gif_1" />
    

    你可以像配置一张普通图片一样,为 SuperTextView 配置展示 Gif 图。

    在代码中配置 Gif

    stv_1 = (SuperTextView) findViewById(R.id.stv_1);
    stv_1.setDrawable(R.drawable.gif_1);
    

    就是这么简单、自然,SuperTextView 可以让你毫无感知,就能配置展示一张 Gif 图。

    SuperTextView 的内核逻辑中,SuperTextView 能够智能的对普通图和 Gif 图进行分类,然后作出相应的处理和优化。

    展示网络 Gif,一样简单

    如果你的 Gif 图不在本地,而在云端,怎么办?

    你无需烦恼!一切放心交给 SuperTextView

    stv_1 = (SuperTextView) findViewById(R.id.stv_1);
    stv_1.setUrlImage("http://example.com/images/example.gif");
    

    只需一行代码,SuperTextView 会在后台协助你完成 Gif 图的加载,然后处理渲染到屏幕上。

    💡实际上,SuperTextViewDrawable1Drawable2 图像展示位,均可用来展示 Gif 图。总之,一切都是你所熟悉的样子。

    你可以掌控的更多

    SuperTextView 所提供给开发者的不仅仅是展示 Gif 图这么简单,你可以掌控更多的细节。

    播放/暂停

    你可以随时控制 Gif 图,播放,或者暂停。

    if (stv.getDrawable() instanceof GifDrawable) {
      // 先获取到 GifDrawable 对象
      GifDrawable gifDrawable = (GifDrawable) stv.getDrawable();
    
      // 播放
      gifDrawable.play();
    
      // 暂停
      gifDrawable.stop();
    }
    

    跳转/获取指定帧

    SuperTextView 中,你可以随时到达你指定的帧图像,以及能够提取到指定帧的图像。

    if (stv.getDrawable() instanceof GifDrawable) {
      // 先获取到 GifDrawable 对象
      GifDrawable gifDrawable = (GifDrawable) stv.getDrawable();
    
      // 跳转到指定帧
      gifDrawable.gotoFrame(pre);
    
      // 获取指定帧
      Bitmap frame = gifDrawable.getFrame(i);
    }
    

    💡由于 SuperTextView 能够支持局部增量渲染,所以当你的 Gif 图支持这种渲染模式时,意味着你可能需要通过调用 gifDrawable.setStrict(true) 开启 严格模式,来确保帧跳转或者帧提取的图像是正确的。这可能会花费一些时间,所以你应该尽量将 严格模式 下的操作放到异步线程中进行。

    快慢,随你心

    SuperTextView 允许你随意的修改 Gif 图的播放速率。

    if (stv.getDrawable() instanceof GifDrawable) {
      // 先获取到 GifDrawable 对象
      GifDrawable gifDrawable = (GifDrawable) stv.getDrawable();
    
      // 设置帧播放间隔时间,20ms
      gifDrawable.setFrameDuration(20);
    }
    

    你可以了若指掌

    通过 SuperTextView 你可以对一张 Gif 图像的信息了若指掌。

    • 获取 Gif 尺寸

      // 获取宽度
      int width = gifDrawable.getWidth();
      
      // 获取高度
      int height = gifDrawable.getHeight();
      
    • 获取 Gif 帧信息

      // 获取帧数
      int frameCount = gifDrawable.getFrameCount();
      
      // 获取当前帧间隔
      int frameDuration = gifDrawable.getFrameDuration();
      
      // 获取当前渲染到那一帧
      int framePotision = gifDrawable.getCurrentFrame();
      
      // 是否在播放
      boolean isPlaying = gifDrawable.isPlaying();
      

    更出彩的 Gif

    SuperTextView 凭借对 Gif 渲染的无缝融合,此前 Drawable1Drawable2 的一切配置项,在展示 Gif 图时,也同样能够生效。

    Gif 作为普通 Drawable

    app:stv_state_drawable_rotate="90"
    

    来看看在原本的 Drawable 位置放上一张 Gif 图会发生什么神奇的事情。

    <com.coorchice.library.SuperTextView
        android:layout_width="match_parent"
        android:layout_height="50dp"
        android:paddingLeft="62dp"
        android:paddingRight="10dp"
        android:text="小火箭发射了!啦啦啦啦啦啦..."
        android:textColor="#ffffff"
        android:textSize="22dp"
        app:stv_corner="6dp"
        app:stv_isShowState="true"
        app:stv_solid="#0D1831"
    
        // 设置 Gif
        app:stv_state_drawable="@drawable/gif_1"
    
        // 设置 Gif 高
        app:stv_state_drawable_height="40dp"
    
        // 设置 Gif 宽
        app:stv_state_drawable_width="40dp"
    
        // 设置 Gif 居左展示
        app:stv_state_drawable_mode="left"
    
        // 设置 Gif 左间距
        app:stv_state_drawable_padding_left="10dp"/>
    

    效果是...

    现在,将 Gif 旋转 90 度试试。

    <com.coorchice.library.SuperTextView
        ...
        // 设置 Gif 旋转 90 度
        app:stv_state_drawable_rotate="90"
        ...
    />
    

    将 Gif 圆角化

    SuperTextView 不可思议的实现了 Gif 图的圆角化,为开发者提供了更多的可能。

    然而,实现这种效果却惊人的简单。

    <com.coorchice.library.SuperTextView
        android:layout_width="185dp"
        android:layout_height="138.75dp"
        android:layout_gravity="center_horizontal"
        app:stv_corner="20dp"
    
        // 设置 Gif 作为控件背景
        app:stv_drawableAsBackground="true"
    
        app:stv_scaleType="fitCenter"
    
        // 配置 Gif
        app:stv_state_drawable="@drawable/gif_1" />
    

    为 Gif 加上边框

    你甚至可以轻而易举的给一张 Gif 图加上边框。

    <com.coorchice.library.SuperTextView
        android:layout_width="350dp"
        android:layout_height="148.4dp"
        android:layout_gravity="center_horizontal"
        android:gravity="center"
    
        // 加上文字会显的更有格调
        android:text="SuperTextView"
    
        android:textSize="36dp"
        android:textStyle="bold"
        android:visibility="invisible"
        app:stv_corner="6dp"
        app:stv_drawableAsBackground="true"
        app:stv_isShowState="true"
        app:stv_scaleType="center"
    
        // 设置边框颜色
        app:stv_stroke_color="@color/opacity_8_gray_4c
    
        // 设置边框宽度
        app:stv_stroke_width="5dp"
    
        app:stv_text_fill_color="#ccffffff"
        app:stv_text_stroke="true"
        app:stv_text_stroke_color="#cc000000"
        app:stv_text_stroke_width="2dp"
    
        // 配置 Gif
        app:stv_state_drawable="@drawable/gif_1"/>
    

    效果即刻呈现...

    轻松实现动态头像

    在过去,一些炫酷的动效,往往会止步于实现的复杂度和成本。而 SuperTextView 为你带了更多的可能,你的灵感可以无拘无束。

    比如,动态头像的实现,可能是迄今为止最简单的。

    <com.coorchice.library.SuperTextView
        android:layout_width="80dp"
        android:layout_height="80dp"
        android:layout_marginLeft="30dp"
        app:stv_corner="40dp"
    
        // 设置为背景图
        app:stv_drawableAsBackground="true"
    
        // 配置 Gif 头像
        app:stv_state_drawable="@drawable/gif_avatar"
    
        // 添加边框
        app:stv_stroke_color="#ffffff"
        app:stv_stroke_width="3dp"
        />
    

    在代码中,你可以直接配置一张网络动态头像。

    stv.setUrlImage("http://gif_avatar.gif");
    

    更多的惊喜

    两个 Drawable 都支持点击!

    在新版本的 SuperTextView 中,Drawable1Drawable2 被赋予了全新的能力 —— 支持精确的响应点击动作。

    SuperTextView 通过监控点击动作发生的位置,能够准确的定位到其所发生的区域(Drawable1Drawable2 或者 其它区域),然后触发相应的回调监听。

    你可以为 SuperTextView 设置 Drawable 上的点击动作监听器,以便在动作发生时,作出必要的响应。

    stv.setOnDrawableClickedListener(new SuperTextView.OnDrawableClickedListener() {
        @Override
        public void onDrawable1Clicked(SuperTextView stv) {
            // Drawable1 clicked,do something...
        }
        @Override
        public void onDrawable2Clicked(SuperTextView stv) {
            // Drawable2 clicked,do something...
        }
    });
    
    stv.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View v) {
            // 非 Drawable 区域被点击,do something...
        }
    });
    

    背景图缩放模式支持

    现在,当你将 Drawable1 作为背景图时,你可以为它配置不同的缩放模式,以达到你心仪的效果。

    stv.setScaleType(ScaleType.CENTER);
    

    SuperTextView 为开发者提供了多达 3 种缩放模式:

    • ScaleType.FIT_XY

      将图片拉伸/压缩平铺。

    • ScaleType.FIT_CENTER

      将图片自适应居中。

    • ScaleType.CENTER

      将图片剪裁居中。默认值。

    其它更新

    • XML 布局文档中,Drawable1Drawable2 现在支持直接设置 颜色 或者 ShapeDrawable

      // circle_f9ad36 为 xml 中编写的 shape 文件
      app:stv_state_drawable="@drawable/circle_f9ad36"
      
      // 使用纯色作为 Drawable
      app:stv_state_drawable="#000000"
      
    • ⚠️ 最低支持版本 API 提升到 19

    • 渲染性能比过去提升至少 30%

    • 升级默认图片加载引擎,支持智能缓存。也许现在,你不必再引入第三方图片加载库了。

    💡随着 5G 带来更快的网速,以及设备性能越来越强悍,用户界面会越来越需要更多的动态展示(过去大量的静态用户界面实在是太死气沉沉了)来刺激使用者的感官,激发用户的兴趣。而 SuperTextView 能够帮助开发者轻松的完成即将到来的这一过渡转变。

    如何开始 SuperTextView v3.2.1 ?

    在项目 build.gradle 中加入:

    dependencies {
        ...
    
        implementation 'com.github.chenBingX:SuperTextView:v3.2.1'
    
        ...
    }
    

    传送门区域


    Source code(tar.gz)
    Source code(zip)
  • v3.2.0.3(Sep 15, 2019)

  • v3.2.0.2(Sep 14, 2019)

  • v3.2.0.1(Aug 13, 2019)

  • v3.1.6.2(Mar 20, 2019)

  • v3.1.6.1(Mar 20, 2019)

    1.修复当StateDrawable被作为图片展示时,默认设置的图片,会因无法清除状态,而导致网络加载的新图无法替换默认图的问题。 2.9.0 出现2次测量,首次测量 width = 0,height = 0,但仍然进行绘制流程,这回导致后面一系列的问题

    Source code(tar.gz)
    Source code(zip)
  • v3.1.6(Mar 20, 2019)

    1. 修复当StateDrawable被作为图片展示时,默认设置的图片,会因无法清除状态,而导致网络加载的新图无法替换默认图的问题。
    2. 9.0 出现2次测量,首次测量 width = 0,height = 0,但仍然进行绘制流程,这回导致后面一系列的问题
    Source code(tar.gz)
    Source code(zip)
  • v3.1.5(Mar 2, 2019)

    1. 修复因使用 StateDrawable 设置颜色或形状作为背景时,会引起的崩溃。
    2. StateDrawable 支持直接在 xml 中设置 颜色ShapeDrawable
    Source code(tar.gz)
    Source code(zip)
  • v3.1.4(Feb 8, 2019)

    1.修复 Drawable2 的 tint 和 rotate 属性受 Drawable 的影响。 2.修复因 singleLine 和 lines 属性导致的 stv 绘制内容消失或错位的问题

    Source code(tar.gz)
    Source code(zip)
  • v3.1.3(Dec 10, 2018)

  • v3.1.2(Nov 30, 2018)

  • v3.1.1(Nov 5, 2018)

    ![](https://raw.githubusercontent.com/chenBingX/img/master/stv/SuperTextView_yuan 2.png)

    诚意之作,SuperTextView (v3.1.1)

    SuperTextView 被打造来帮助 Android 开发者更高效、更便捷、更优雅的开发 Android 应用。

    现在,这一诚意之作再次升级。全新的 SuperTextView 将向 Android 开发者开放更多可能性,当然一如既往,SuperTextView 也带来了更多高效的功能。

    神奇的着色

    SuperTextView 此次的升级,为 StateDrawable 增加了神奇而强大的着色能力。开发者可以轻松的改变一个图标的颜色,而不用再增加一个仅仅是颜色不同的图标到项目中。这项技术将为你的 Android 应用程序带来一次瘦身的机遇。

    # 修改 drawable 的颜色
    app:stv_state_drawable_tint="@color/gray"
    
    # 修改 drawable2 的颜色
    app:stv_state_drawable2_tint="@color/red"
    

    只需要如此一行简单的代码,就能瞬间赋予一张图片千变万化的能力。想要任何色彩,当然是你说了算。而这一切的发生,无需再引进另外一张图片。

    在 Java 代码中,有与之对应 set/get 函数,让开发者可以在任何时候都能施展魔法,改变一张图片的色彩。

    七十二般变化

    对 StateDrawable 的增强,不仅仅限于颜色的变换。SuperTextView 更被赋予了改变 StateDrawable 形态的能力。同样的一张图,开发者可以组合出无数种可能。

    只需简单的几行代码,你便可以随心所欲的变换任何一张图片。

    # 修改 drawable 的旋转角度
    app:stv_state_drawable_rotate="90"
    
    # 修改 drawable2 的旋转角度
    app:stv_state_drawable2_rotate="90"
    

    无需复杂的代码,SuperTextView 一如既往的简洁、优雅。

    同样,在 Java 代码中,也提供了对应的 set/get 函数。

    这项能力,可以有效的帮助开发者将 Android 应用的体积向着极致的方向压缩。

    精彩远不止于此

    这就是渐变文字!

    SuperTextView 所提供的可能是目前为止实现渐变文字最简洁、优雅的解决方案。只需要简单的配置,就能实现酷炫的渐变文字效果。

    # 是否启用渐变色文字
    app:stv_textShaderEnable="true"
    
    # 设置文字的起始渐变色
    app:stv_textShaderStartColor="@color/red"
    
    # 设置文字的结束渐变色
    app:stv_textShaderEndColor="@color/yellow"
    
    # 设置文字的渐变的模式
    # leftToRight:左 -> 右
    # rightToLeft:右 -> 左
    # topToBottom:上 -> 下
    # bottomToTop:下 -> 上
    app:stv_textShaderMode="leftToRight"
    

    这些属性也在 Java 中开放了 set/get 接口,便于开发者随时动态的修改它们。

    开放了新的 API

    1. Adjuster 增加 onAttach、onDetach

    Adjuster 增加了两个新的函数:

    • onAttach():当 Adjuster 被设置到一个 SuperTextView 中时会被调用。
    • onDetach():当 Adjuster 被从一个 SuperTextView 中移除时会被调用。

    通过在 Adjuster 中重写这两个函数,开发者可以在正确的时机进行状态注册、初始化,或者取消注册、释放资源等操作。

    public class MyAdjuster extends SuperTextView.Adjuster{
    
        @Override
        protected void adjust(SuperTextView superTextView, Canvas canvas) {
          
        }
    
        @Override
        public void onAttach(SuperTextView stv) {
          // 当 Adjuster 被加入一个 SuperTextView 时会被调用
        }
    
        @Override
        public void onDetach(SuperTextView stv) {
          // 当 Adjuster 被从 SuperTextView 移除时会被调用
        }
    }
    

    2. 提供 getAdjusterList() 函数

    这个函数可以让开发者获得一个 SuperTextView 中的所有 Adjuster。如果 SuperTextView 中没有 Adjuster 的话,将会返回 null。

    ⚠️ 你必须重视这些变化

    1. 属性增加了 stv_ 前缀

    现在,SuperTextView 的所有属性都加上了前缀 stv_

    这样做可以避免当开发者引入的其它第三方库时,与 SuperTextView 可能产生的属性名冲突。

    如果开发者目前正在使用一个此前版本的 SuperTextView,那么当升级到新的版本后,需要在所有 xml 中的属性前加上 stv_ 前缀。

    得益于现代 IDE 的强大,开发者可以轻松的完成这些工作。就像下面这样。

    app:corner="10dp"
    

    corner 是旧版本中的属性名称,升级到新版本后,需要在前面增加 stv_ 前缀,变为 stv_corner

    如果开发者使用的是 AndroidStudio,从 Edit > Find > Replace 打开批量替换对话框,然后按照下图操作即可。

    如果开发者的项目中只有 SuperTextView 使用了相同的命名空间(如 app),那么很幸运,你可以直接将 app: 替换为 app:stv_ 即可。

    2. setAdjuster(Adjuster) 已被移除

    从 SuperTextView v2.0 版本开始,setAdjuster(Adjuster) 函数就被标记为了将被移除的状态,同时加入了新的函数 addAdjuster(Adjuster) 作为替代。

    在新的版本中,setAdjuster(Adjuster) 函数将被正式移除,如果开发者此前使用了该方法,请将其修改为 addAdjuster(Adjuster)

    如何开始 SuperTextView v3.1.1

    dependencies {
    	 compile 'com.github.chenBingX:SuperTextView:v3.1.1'
    }
    

    SuperTextView Github 【传送门】

    Source code(tar.gz)
    Source code(zip)
  • v3.1(Nov 5, 2018)

  • v3.0.0(May 13, 2018)

    抱歉,这是你期待已久SuperTextView(v3.0)

    image

    Insight.io

    SuperTextView

    SuperTextView 诞生之初,便始终坚持一个愿景,即帮助 Android 开发者愉悦的去构建一个应用。

    经过一年多的不断的聆听、思考、探索、验证, SuperTextView 完成了多次迭代,改善了一些问题,新增了一些功能,不断的完善,以带给开发者更好的开发体验。

    如今, SuperTextView 已经具备了诸如圆角、边框、描边、按压变色、多状态图、圆角图、万能的 Adjuster 、加载网络图片等一系列的常用功能。得益于此,开发者能够轻松实现各种原本十分麻烦的效果,节省大量的开发时间,有效减少页面的复杂度,降低项目维护成本。

    写代码,本应如此愉悦!

    1. 链接云端的SuperTextView

    早在几个月前,就开始有很多开发者向 CoorChice 建议,是否能够让 SuperTextView 具备加载网络图片的功能。其实这也是 CoorChice 很久之前就有考虑过的,但在 SuperTextView 的早期,完善其核心功能仍然是首要目标,所以一直没涉猎到图片相关的功能。

    直到上一个大版本,SuperTextView v2.0CoorChie 才尝试添加了图片展示的功能。这使得SuperTextView 可使用的范围得到了扩大,同时针对图片也推出了给图片增加描边、设置圆角、设置状态图等功能。相关使用文档可到以下链接查阅:

    【你好, SuperTextView】 - https://www.jianshu.com/p/1b91e11e441d

    这一次尝试,获得了开发者们不错的反响,大家对于使用 SuperTextView 去展示处理图片是有所期待的。上一个版本发布后,开发者们对于一个能展示网络图片的 SuperTextView 似乎更加的感兴趣了。

    那么,现在,你所期待已久的 SuperTextView 在此!

    1.1 加载一张网络图片

    显示一张网络图片,在 SuperTextView 中只需要如下代码:

    SuperTextView stv_1 = (SuperTextView) findViewById(R.id.stv_1);
    //填入图片Url
    stv_1.setUrlImage(url);
    

    效果就如上图中的第二个显示头像的例子一样。

    如果你希望将网络图片作为 SuperTextView 的 StateDrawable 来展示的话,完全没问题。

    //填入图片Url
    stv_1.setUrlImage(url, false);
    

    第二个参数为 false 表示网络图片将不会被作为背景充满整个 SuperTextView,而是作为一个状态图。当然,有关状态图的一切配置都将运用到此。就像上图中的第一个例子一样,整个布局包括图片、文字、背景都在一个 SuperTextView 中被处理,从网络下载的图片被作为 StateDrawable 放到了图中的位置。

    1.2 SuperTextView中图片引擎

    SuperTextView 为了保持依赖库的纯净和尽可能小的体积,并没有内置任何的图片加载框架。所以默认情况,将使用内置的一个简易图片引擎去下载图片,确保开发者能够正常使用展示网络图片的功能。

    CoorChice 仍然建议开发者根据项目的具体情况,选择一个目前正在使用的图片加载框架,设置到 SuperTextView 中,以用来加载图片。 SuperTextView 具备适配任意图片加载框架的能力。下面 CoorChice 将通过 Glide 和 Picasso 的例子展示如何将现有的图片框架安装到 SuperTextView 中。

    1.2.1 实现图片引擎Engine

    SuperTextView 中,核心的图片加载引擎被抽象成接口 Engine ,开发者需要根据所用的图片框架,实现一个 Engine

    • Glide图片加载框架
    public class GlideEngine implements Engine {
    
      private Context context;
    
      public GlideEngine(Context context) {
            this.context = context;
      }
    
      @Override
      public void load(String url, final ImageEngine.Callback callback) {
            Glide.with(context).load(url).into(new SimpleTarget<GlideDrawable>() {
            @Override
            public void onResourceReady(GlideDrawable resource, GlideAnimation<? super GlideDrawable> glideAnimation) {
                // 主要是通过callback返回Drawable对象给SuperTextView
                callback.onCompleted(resource);
            }
            });
        }
    }
    
    • Picasso图片加载框架
    public class PicassoEngine implements Engine {
    
      private Context context;
    
      public PicassoEngine(Context context) {
            this.context = context;
      }
    
      @Override
      public void load(String url, final ImageEngine.Callback callback) {
            Picasso.with(context).load(url).into(new Target() {
            @Override
            public void onBitmapLoaded(Bitmap bitmap, Picasso.LoadedFrom from) {
                // 主要是通过callback返回Drawable对象给SuperTextView
                callback.onCompleted(new BitmapDrawable(Resources.getSystem(), bitmap));
            }
    
            @Override
            public void onBitmapFailed(Drawable errorDrawable) {
    
            }
    
            @Override
            public void onPrepareLoad(Drawable placeHolderDrawable) {
    
            }
        });
      }
    }
    

    1.2.2 安装图片引擎Engine

    实现好 Engine 后,下一步就是要将其安装到 SuperTextView 中。

    CoorChice 建议可以在 Application的onCreate()中进行安装,这样当需要使用 SuperTextView 加载显示网络图片的时候,就能够用到三方图片框架了。

    public class STVApplication extends Application {
    
      @Override
      public void onCreate() {
        super.onCreate();
        // 安装图片引擎
        ImageEngine.install(new GlideEngine(this));
        // ImageEngine.install(new PicassoEngine(this));
      }
    }
    

    一行代码,轻松安装。

    需要注意的是,任何时候,后安装的 Engine 实例总是会替换掉先前安装的 Engine 实例,即 SuperTextView 只允许全局存在一个 Engine 实例。

    现在,你可以让 SuperTextView 使用指定的三方图片加载框架去加载图片了。

    2. 如何开始SuperTextView v3.0

    	dependencies {
    	   compile 'com.github.chenBingX:SuperTextView:v3.0'
    	}
    
    Source code(tar.gz)
    Source code(zip)
  • v2.0.1(Dec 28, 2017)

  • v2.0(Nov 16, 2017)

    v2.0 - 未来,从现在开始

    一直以来,CoorChice都心存一个设想,期待着能够打造这样一个控件:它能满足你的大部分开发需求,展示文字、图片、几何、动画、状态,让你使用一个控件就能高效的完成大部分开发工作。它是如此的强大,仿佛有心智一般,接受着你的输入,按照你的心意,呈现出叹为观止的画面。随着【SuperTextView v2.0】的到来,我们离这个设想更近了一步。现在,来和【SuperTextView v2.0】见个面吧!

    SuperTextView v2.0

    图片,就是现在

    在【SuperTextView v2.0】中,增加了对图片展示的支持。但不仅仅止于展示图片,它还能智能的根据你的输入将图片剪裁为你期望的形状。

    image

    给图片加上圆角,加上边框,或者直接变成圆形,所有的一切只需要设置几个简单的属性,即刻呈现在你的眼前。

    展示一张图片

    如何使用SuperTextView展示一张图片?只需要在xml中加上下面两句代码即可。

    <com.coorchice.library.SuperTextView
        ...
        app:state_drawable="@drawable/avatar1"
        app:drawableAsBackground="true"
        ...
     />
    

    如果你是SuperTextView的忠实用户的话,你会发现,原本的state_drawable现在可以被用来展示一张图片。

    给图片加上圆角

    现在,你的图片呈现在了你的眼前,也许你还想对它做一些不一样的事情,比如,加个圆角,或者直接变成圆形?没问题,SuperTextView现在完全能胜任这样的工作。

    <com.coorchice.library.SuperTextView
        android:layout_width="100dp"
        android:layout_height="100dp"
        ...
        app:corner="15dp"
        app:state_drawable="@drawable/avatar1"
        app:drawableAsBackground="true"
        ...
     />
    

    如此简单!在原来的基础上你仅仅需要设置合理的corner值就行。

    也许,你还想要边框

    有时候,你可能需要使用一个边框去包裹住你的图片,就像上面的示例那样。没错,这肯定在SuperTextView能力范围内。

    <com.coorchice.library.SuperTextView
        android:layout_width="100dp"
        android:layout_height="100dp"
        ...
        app:corner="50dp"
        app:stroke_color="#F4E187"
        app:stroke_width="4dp"
        app:state_drawable="@drawable/avatar1"
        app:drawableAsBackground="true"
        ...
     />
    

    app:stroke_color 掌控着边框的颜色,app:stroke_width 掌控着边框的宽度。一切如此流畅,一个有心智的控件本该如此,对吗?

    第二个状态图

    面对复杂的需求变化,【SuperTextView】为应对这种复杂性,孕育出了第二个状态图 state_drawable2

    现在,CoorChice将向你展示,上图中的两种效果是如何实现的。

    • 示例一
    <com.coorchice.library.SuperTextView
        android:layout_width="100dp"
        android:layout_height="100dp"
        ...
        app:corner="50dp"
        app:state_drawable="@drawable/avatar1"
        app:drawableAsBackground="true"
        // state_drawable2的配置由此开始
        app:isShowState2="true"
        app:state_drawable2="@drawable/recousers"
        app:state_drawable2_mode="rightTop"
        app:state_drawable2_height="20dp"
        app:state_drawable2_width="20dp"
        ...
     />
    
    • 示例二
    <com.coorchice.library.SuperTextView
        android:layout_width="100dp"
        android:layout_height="100dp"
        ...
        // 背景图
        android:background="@drawable/avatar7"
        // drawable1的配置由此开始
        app:isShowState="true"
        app:state_drawable="@drawable/triangle"
        app:state_drawable_mode="leftTop"
        app:state_drawable_width="20dp"
        app:state_drawable_height="20dp"
        // state_drawable2的配置由此开始
        app:isShowState2="true"
        app:state_drawable2="@drawable/recousers"
        app:state_drawable2_mode="rightTop"
        app:state_drawable2_height="20dp"
        app:state_drawable2_width="20dp"
        ...
     />
    

    就如你所熟悉的一样,state_drawable2 延续了第一代一切流畅的操作。在聪明的你合理的使用下,【SuperTextView】一定能够大放异彩!😉

    属于Adjuster的时代

    此前,Adjuster 的设计使得【SuperTextView】具有了灵魂,成为更聪明的控件。对绘制过程的插入,触摸事件的捕捉,使得你能轻松的从外部改变一个控件的状态。创意始于心,而行于此。

    现在,【SuperTextView】能够同时承载最多3个 Adjuster !也许,你的创意会更加的炫目。

    在上面这个示例中,CoorChice将早起的两个【扫光】和【涟漪】特效都加入到了一个【SuperTextView】中,结果就是你看到的这样。

    更多的 Adjuster 意味着更多的组合,更多的惊喜。在【v1.4.0】中,CoorChice同样使用了 Adjuster 来轻松的实现了按压变色功能。

    这是 Adjuster 的时代,睿智的你一定可以运用它挥洒创意的。

    需要注意的是⚠️,原本的 setAdjuster(Adjuster) 方法目前仍然被保留,但以后的版本将会被移除,你必须要尽快迁移。新的替代方法为 addAdjuster(Adjuster)

    其它

    • 修正控制Shader模式的属性 app:shaderMode="leftToRight" 的拼写。原来为 app:shaderMode="leftTopRight" 。如果你使用了该属性,在升级【SuperTextView v2.0】后请及时修正。
    • 增加 set/getPressBgColor()set/getPressTextColor() 用于在代码中控制按压背景色。
    Source code(tar.gz)
    Source code(zip)
  • v1.4(Aug 2, 2017)

  • v1.3(May 26, 2017)

  • v1.2.1(May 13, 2017)

Useful library to use custom fonts in your android app

EasyFonts A simple and useful android library to use custom fonts in android apps without adding fonts into asset/resource folder.Also by using this l

Vijay Vankhede 419 Sep 9, 2022
⚡️A highly customizable, powerful and easy-to-use alerting library for Android.

Flashbar A highly customizable, powerful and easy-to-use alerting library for Android. Specs This library allows you to show messages or alerts in you

Aritra Roy 1.7k Dec 7, 2022
A simple, customizable and easy to use swipeable view stack for Android.

SwipeStack A simple, customizable and easy to use swipeable view stack for Android. QuickStart Include the Gradle dependency dependencies { compil

Frederik Schweiger 1.5k Dec 30, 2022
Library and example project on how to use the UITableView component

UITableView for Android Usage Installation Android Studio Paste or clone this library into the /libs folder, in the root directory of your project. Cr

Thiago Locatelli 679 Nov 11, 2022
A small, easy to use android library for implementing flipping between views as seen in the popular Flipboard application

FlipView About This library is made to be very easy to use and at the same time be feature complete. With only a few lines of code you can have a flip

Emil Sjölander 924 Nov 10, 2022
A color picker and a color preference for use in Android applications.

HSV-Alpha Color Picker for Android This library implements a color picker and a color preference for use in Android applications. Features I couldn't

Martin Stone 279 Nov 26, 2022
A lovely snail,You can use it as a seekbar or progressbar.

SnailBar A lovely ,you can use it as a seekbar or progressbar. Helixbar design by Davlikanoff.This is his words: Hi Guys! This 18 seconds long animati

CJJ 527 Jun 10, 2022
Step by step,just use HorizontalStepView,VerticalStepView. step indicator,flow indicator,timeline,order process,express status

StepView Step by step. Step indicator. Flow indicator。 snapshot like this:HorizontalStepView like this also like this:VerticalStepView Yeah,I am not w

baoyachi. Aka Rust Hairy crabs 4.1k Dec 30, 2022
A simple use of canvas to make real life clock

ClockView A simple use of canvas to make real life clock PR-viewer

Kishan Kumar 0 Dec 18, 2021
Xamarin.Android provides open-source bindings of the Android SDK for use with .NET managed languages such as C#

Xamarin.Android Xamarin.Android provides open-source bindings of the Android SDK for use with .NET managed languages such as C#. Build Status Platform

Xamarin 1.8k Jan 5, 2023
Welcome Fruit Ninja 🥝 on Jetpack Compose Desktop 🚀, using Canvas API 🎨

Compose-Fruit-Ninja ?? Welcome Fruit Ninja on Jetpack Compose Desktop ?? , using Canvas API ?? Featured on jetc-dev How to Run From gradle tab from ri

Chetan Gupta 54 Nov 2, 2022
****. Use the native and support library variants instead - https://developer.android.com/guide/topics/ui/look-and-feel/fonts-in-xml.html. An android library that makes it easy to add custom fonts to edittexts and textviews

Add to your project Add this line to your dependencies in build.gradle compile 'in.workarounds.typography:typography:0.0.8' Using the views There are

Workarounds 43 Nov 6, 2021
An tool to help developer to use Retrofit elegantly while using kotlinx.coroutines.

one An tool to help developer to use Retrofit elegantly while using kotlinx.coroutines. Feature Transform different data structs to one. {errorCode, d

ChengTao 30 Dec 27, 2022
Stetho is a debug bridge for Android applications, enabling the powerful Chrome Developer Tools and much more.

Stetho Stetho is a sophisticated debug bridge for Android applications. When enabled, developers have access to the Chrome Developer Tools feature nat

Facebook 12.6k Jan 7, 2023
:rocket: Ultimate Android Reference - Your Road to Become a Better Android Developer

The goal of this project is to provide a hand-picked collection of Android libraries, tools, open-source projects, books, blogs, tutorials - you name

Aritra Roy 7.6k Jan 4, 2023
Deprecated in favour of https://developer.android.com/reference/android/support/v4/view/animation/PathInterpolatorCompat.html

Deprecated: use https://developer.android.com/reference/android/support/v4/view/animation/PathInterpolatorCompat.html instead. android-cubic-bezier-in

Codesoup 161 Jan 1, 2023
[UNMAINTAINED][Android] Bluetooth Serial Port Profile which comfortable to developer application to communication with microcontroller via bluetooth

⚠ WARNING: This project is no longer being maintained Android-BluetoothSPPLibrary Bluetooth Serial Port Profile which comfortable to developer applica

Akexorcist 1.7k Dec 31, 2022
Android validation library which helps developer boil down the tedious work to three easy steps.

AwesomeValidation Introduction Implement validation for Android within only 3 steps. Developers should focus on their awesome code, and let the librar

Jing Li 1.1k Dec 17, 2022
Android Phishing Application.This Project is for Educational purposes only.The Developer of this application is not responsible of any bad usage

Android Phishing Application.This Project is for Educational purposes only.The Developer of this application is not responsible of any bad usage

Aria Shirazi 93 Oct 23, 2022
Advancement Utils for Android Developer written in Kotlin

RichUtils About Version: 2.0.0 :: Dreaming Bird (夢魅鳥, Yumemidori) :: Release Note (Eng) : https://blog.uzuki.live/richutils-2-0-0-dreaming-bird-releas

WindSekirun (wind.seo) 169 Nov 13, 2022