I have a problem with the text not displaying properly on my screen, It appears as a blank rectangle with the same text color, Just no text...
Everything else works fine though, Menus and crosshair and other 2D stuff renders fine. I'm using this tutorial: http://www.lwjgl.org/wiki/index.php?title=Slick-Util_Library_-_Part_3_-_TrueType_Fonts_for_LWJGL
getting this result:
EDIT: I managed to fix that issue, But now I have another problem, Text is displaying with a black background, Like this guys issue: http://www.java-gaming.org/index.php?topic=26944.0
but his fix which is disabling depth test does not work for me...
You might need to change the order in which your objects are rendered.To make sure it works correctly they should be rendered in back to front order. See here
Are you enabling GL_BLEND? If so, try setting glDepthMask(false); after the glDisable(GL_DEPTH_TEST).
Related
I'm trying to build a line graph that only shows the vertical highlight when you touch or drag on the graph. I'm able to remove the highlight completely and even have an image show up on where I touch or drag it. But so far, I haven't been able to remove the horizontal line. I used these other resources to try and get it to work, but they haven't really done much for me yet.
MPAndroidChart LineChart custom highlight drawable
https://www.programmersought.com/article/1729477382/
https://weeklycoding.com/mpandroidchart-documentation/highlighting/
I'm using the latest version, 3.1. I read here on one of the issues that you couldn't remove the horizontal line in older versions of the library. https://github.com/PhilJay/MPAndroidChart/issues/814 But I assume that maybe they did something to change that.
LineChart line_data_chart = v.findViewById(R.id.line_data_chart);
line_data_chart.getAxisLeft().setEnabled( false );
line_data_chart.getAxisRight().setEnabled( false );
line_data_chart.getLegend().setEnabled( false );
line_data_chart.getXAxis().setEnabled( false );
line_data_chart.getDescription().setEnabled( false );
line_data_chart.setScaleEnabled( false );
line_data_chart.setOnChartValueSelectedListener( new CustomChartGestures() );
line_data_chart.setMarker( new MarkerImage(getContext(), R.drawable.home_icon));
//line_data_chart.setHighlightPerTapEnabled( false );
This is my code so far. I was thinking of making an image of a vertical line and using that instead of the home icon. But I feel like there is an easier way. I also thought of implementing the Highlight class but it still seems like overkill. I've been searching for a couple of hours at this point. Any kind of suggestion is very much appreciated.
If I understand correctly you are trying to remove the horizontal highlight line
Maybe this question will help - How to disable highlight line in MPAndroidChart?
dataSet.setDrawHorizontalHighlightIndicator(false)
So I ended up just using an image that would change size with different size screens but this doesn't seem like the most optimal solution.
If anyone has any better answer to this problem please share it. I would greatly appreciate it.
I have a really weird error that I'm trying to resolve. On a website I built with the visual composer, one of the buttons that leads to an internal anchor (#whatwedosmall) on the same site just wont work on the mobile layout.
This is the site: https://b8j3ssh.myraidbox.de/
I created 3 layouts (large, medium, small) and each section has a certain ID (for example the What we do section in large is named: #whatwedolarge and so on. Within the site there are buttons that lead to these sections and it works great!
However, the very first button on mobile (breakpoint smaller than 600px) just wont work at all. I tried everything but I cannot get it to work...
Can you help me?
When you inspect the page at a breakpoint < 600px you can see that your button (actually an ) is being covered by the rev_slider_1_1 so the actual can never be hovered or clicked.
If you delete that slider from the DOM in DevTools or set the height manually, then the hovering and click work. As you can see in the screenshot below, manually setting the Slider height to 850px allows me to hover and click
You need to determine how the height of that slider is being determined and fix that in your code.
Currently, I am making a music discord bot and I want it to display the list of songs it is currently playing.
The user should be able to interact with the list by moving to each page with a left arrow and right arrow emoji.
The problem is that, when I try to react to the message via a unicode, it does not seems to work as follows:
message.addReaction("U+2B05").queue();
message.addReaction("U+2B07").queue();
it throws an error saying that the Emoji is not found during runtime, even though that is the respective unicode for the emoji I wanted to sent.
I have tried to use 2B05 or Left Arrow in the string and it does not work too.
Encountered the same issue before, though one of the answers from this question helped me.
Specifically, one of the answer was:
I understood how to do it. Just need to add this line
e.getChannel().sendMessage(embedBuilder.build()).complete().addReaction("✔").queue();
Apparently adding the emoji directly into the string works.
Do this instead:
message.addReaction("➡").queue();
message.addReaction("⬅").queue();
I wanted to print a few programs for a school project on bluej. When I click the print button and set the paper size to A4 and give 'OK' the print comes in a weird small box. I tried increasing the font size. No changes happened. I also changed the page type to the different ones available, but no luck. Please tell me how to solve this problem.
There are two possible ways to solve your problem. The first is to copy-paste your code into another program, for example Word. The second way is to printscreen the code you want to print and then spread this picture across the A4. Maybe you should cut the edges off first.
I have been looking through forum posts, blogs, videos, and various other websites for the past hour trying to figure out how to display text on the screen. From what I have seen this is not very simple to do. (Maybe it is once you know how to actually do it)
I decided (with a bit of regret) to post this question here. I am sorry if this question has already been asked a million times, but I am just not understanding how to get this to work. All of the code I have tried so far has not worked.
I would just like to know how I can display text on the screen. I do not want to use my own font or anything fancy. I would just like to know the simplest way to display text on the screen.
The simplest way would be to use Slick. Here's a link to the page specifically about loading and using fonts within your LWJGL program:
Slick-Util (Part 3) - TrueType Fonts for LWJGL
I am learning java currently and I love the newbostin, he makes simple fast tutorials but to display text I'm pretty sure u need to
1: have eclipse
2: make the base of it (the main string, idk how actually)
3. The actual code to do it is println("text here")
I'm not completely sure so you should check out the newBoston he is awesome at explaining.