Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

342
Views
Cómo aplicar la animación Blink en el color del texto de la casilla de verificación

Tengo un método de parpadeo, pero esto solo funciona para toda la casilla de verificación. Solo quiero parpadear el texto dentro de la casilla de verificación. Alguien sabe cómo hacer esto? Y también, ¿cómo puedo cambiar el color del texto cuando parpadea?

Código de parpadeo:

 fun View.blink( times: Int = Animation.INFINITE, duration: Long = 300L, offset: Long = 100L, minAlpha: Float = 0.0f, maxAlpha: Float = 1.0f, repeatMode: Int = Animation.REVERSE ) { startAnimation(AlphaAnimation(minAlpha, maxAlpha).also { it.duration = duration it.startOffset = offset it.repeatMode = repeatMode it.repeatCount = times }) }

y luego en la casilla:

 checkBoxText.blink(3)
over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

Puede animar el textColor , no afectará el cuadro. Aquí hay un ejemplo para parpadear el texto rojo.

 val colorAnimator = ObjectAnimator.ofInt( myCheckBox, "textColor", Color.argb(255, 255, 0, 0), Color.argb(0, 255, 0, 0) ) colorAnimator.setEvaluator(ArgbEvaluator()) colorAnimator.repeatCount = 3 colorAnimator.duration = 2000 colorAnimator.start()
over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!