Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8447919
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T10:17:44+00:00 2026-06-10T10:17:44+00:00

After following a Slick2D tutorial on custom fonts, it provided me with the following

  • 0

After following a Slick2D tutorial on custom fonts, it provided me with the following code to initialise it:

titleFont.addAsciiGlyphs();
titleFont.addGlyphs(400, 600);
titleFont.getEffects().add(new ColorEffect()); //Type safety: The method add(Object) belongs to the raw type List. References to generic type List<E> should be parameterized
titleFont.loadGlyphs();

Eclipse throws the commented warning on that line. Can you please answer with a replacement to line 3 with whatever Eclipse is asking me to put in there.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T10:17:45+00:00Added an answer on June 10, 2026 at 10:17 am

    That warning is telling you the list returned by getEffects() is not parameterized. It is of type List. Since that list is inside the Slick library, you can’t really do anything about that warning. Just carry on.

    Here is the source code, I’m guessing you are using Unicode font: https://bob.newdawnsoftware.com/repos/slick/trunk/Slick/src/org/newdawn/slick/UnicodeFont.java

    You can see for yourself that the effects are stored in a List rather than being parameterized.

    I was wrong in my initial comment, the error isn’t because of type erasure, its because the effects list is raw. See this: What is a raw type and why shouldn't we use it?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

After following the RoR getting started tutorial, I added another model as: $ rails
After following this MVC 4 tutorial series I was trying some of the stuff
After following the steps outline in this Fluent NHibernate tutorial I am stuck on
When working on the Hello, Gallery tutorial/sample app, after following the instructions on the
After following a beginners tutorial I ended up combining a bunch of lessons to
I'm using jquery_token_input after following Ryan Bates railscast #258 and this is the code
my setup is ubuntu - gitolite - msysgit. After following this tutorial : https://sites.google.com/site/senawario/home/gitolite-tutorial
After following the official tutorial here: tutorial I'm still having issues adding rows/creating a
After following code and showing no errors when I use my button to access
After following a tutorial Ive found. Im now redoing it again, without the scaffolding

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.