Skip to content
Advertisement

JEditorPane – make tabs spaces

I’m wondering if there’s a way to have tabs convert to spaces in a jeditorpane, much like you’d see when working in an IDE. I don’t want to set the tab size. I can already do that easily. I want to have tabs replaced with their equivalent in spaces. So for example if my tabs are 5 spaces long, I

Circle approximations using Bezier curves

I have 2 questions about bezier curves, and using them to approximate portions of circles. Given the unit circle arc (1,0)->(cos(a),sin(a)) where 0 < a < pi/2, will it result in a good approximation of this arc to find the bezier curve’s control points p1, p2 by solving the equations imposed by the requirements B(1/3) = (cos(a/3), sin(a/3)) and B(2/3)

How to check whether the file is binary?

I wrote the following method to see whether particular file contains ASCII text characters only or control characters in addition to that. Could you glance at this code, suggest improvements and point out oversights? The logic is as follows: “If first 500 bytes of a file contain 5 or more Control characters – report it as binary file” thank you.

JSF 1.0 vs JSF 2.0

What is difference between these 2 version of JSF (JSF 1.0 and JSF 2.0)? As I am new to java, I only find that difference is at Architectural level. But, in perspective, I can’t get how much it affects the application development ? Also, the MVC imposed is different with JSF and Spring. Even if JSF has improved architecture, still

java: sparse bit vector [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers. We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations. Closed 19 days ago. Improve this question Are there any well-known libraries in Java for sparse bit vectors?

GPS Time Representation library

I am looking for a Java library that handles conversion to/from GPS Time. GPS Time has an epoch of 6 January 1980, and does not have leap seconds, so it differs from the more standard time representations. Here is the relevant description from wikipedia: While most clocks are synchronized to Coordinated Universal Time (UTC), the atomic clocks on the satellites

Advertisement