Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

20
LINES

< > BotCompany Repo | #1035750 // jMaxSpeedAnimationWithText

JavaX fragment (include) [tags: use-pretranspiled]

Transpiled version (19404L) is out of date.

static JComponent jMaxSpeedAnimationWithText(IF0_Pair<BufferedImage, O> renderFrameWithText) {
  new ImageSurface is;
  is.pixelate(true);
  is.autoZoomToDisplay(true);
  new DoubleFPSCounter fps;
  var textArea = typeWriterFont(uneditableTextArea());
  awtCalcContinuously(is, -> {
    try {
      var imageAndText = renderFrameWithText!;
      fps.inc();
      is.setImage(pairA(imageAndText));
      setText(textArea, nlCombine_rtrim(fps, pairB(imageAndText)));
    } catch print e {
      setText(textArea, exceptionToStringShort(e));
      sleepSeconds(1); // error penalty
    }
  });
  
  ret jvsplit(jscroll_center_borderless(is), textArea);
}

Author comment

Began life as a copy of #1035612

download  show line numbers  debug dex  old transpilations   

Travelled to 2 computer(s): elmgxqgtpvxh, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1035750
Snippet name: jMaxSpeedAnimationWithText
Eternal ID of this version: #1035750/4
Text MD5: 162336e5d1072db44880baf82ea0ad3a
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-07-22 02:41:10
Source code size: 670 bytes / 20 lines
Pitched / IR pitched: No / No
Views / Downloads: 62 / 97
Version history: 3 change(s)
Referenced in: [show references]