0 votes
in Education by (1.3m points)
I'm a little new to the web development scene and I was having a very persistent problem with Chrome that I can't quite seem to figure out.

I'm using the Compact News Previewer to show new entries to the database. You'll notice that if you view the demo in Firefox everything fits nice and snug, but in Chrome the paragraphs within the left-hand column get truncated. I'm having this same issue in my own implementation as seen below (Note: My implementation is a little different from the demo):

You can see this issue for yourself if you go to this website.

What I've tried:

CSS Reset - yields no different results.

Edit

I'm using Chrome V18.0.1025.151, going to try a system update on Ubuntu so I'll check in tomorrow and see if this fixes the issue.

Edit 2 Evidently I'm using the latest version of Google Chrome, might be a problem with this version. But if nobody else can see the issue then perhaps it's a non-issue...

Edit 3 Found out that I was using Chromium instead of Chrome, I didn't realize there was a difference. I installed Chrome 7 instead but I'm getting the same problem as with Chromium. Also suddenly neither of these browsers are able to display some of my jpg images? C̶h̶r̶o̶m̶e̶ ̶m̶u̶s̶t̶ ̶b̶e̶ ̶i̶n̶c̶r̶e̶d̶i̶b̶l̶y̶ ̶b̶u̶g̶g̶y̶ ̶o̶n̶ ̶U̶b̶u̶n̶t̶u̶!̶ <-- Human-error!

JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by (1.3m points)
It seems like the issue is due to Chrome's default line-height and the fonts that you are using on the page. Myriad Pro and Trebuchet MS seem to have very wide leading when used with Chrome's default; sans-serif is fine. Since .cn_list p has a fixed height and overflow:hidden set, the huge line-height Chrome gives these fonts pushes the text out of the box, cutting it off.

You have a couple of options:

Specify a line-height value in your .cn_list p rule or in a rule for a parent element, like body to cascade it down. (Something like 1 or 1em will tighten it up, but YMMV.)

Remove the fixed height and hidden overflow, which would probably break your design since it would ruin the grid.

Adding a line-height should do the trick for you there, though.

Projects like HTML5Boilerplate always set a default line-height for just this reason.

Learn More with Blogmepost

blogmepost Online Test

NCERT Questions & Answers

  • NCERT Class 12 Maths Solutions
  • NCERT Class 12 Physics Solutions
  • NCERT Class 12 Chemistry Solutions
  • NCERT Class 12 Biology Solutions
  • NCERT Class 10 Science Solutions
  • NCERT Class 10 Maths Solutions
blogmepost Q&A

CBSE Questions & Answers Portal

  • CBSE Class 12 Maths Questions Answers
  • CBSE Class 12 Physics Questions Answers
  • CBSE Class 12 Chemistry Questions Answers
  • CBSE Class 12 Biology Questions Answers
  • CBSE Class 10 Science Questions Answers
  • CBSE Class 10 Maths Questions Answers
Blogmepost

Learn Math Formula, Revise Notes

  • JEE Crash Course Questions & Answers
  • NCERT Course Questions and Answers
  • CBSE Board Questions Bank
  • ICSE Board Questions Bank
  • Free Study Materials
  • Question & Answers Bank for All Classes
  • Text Book Solutions
  • Previous Year Question Paper
  • NCERT Book Solutions

  • NCERT
  • NCERT Solutions
  • NCERT Solutions for Class 12 Maths
  • NCERT Solutions for Class 12 Physics
  • NCERT Solutions for Class 12 Chemistry
  • NCERT Solutions for Class 12 Biology
  • NCERT Solutions for Class 11 Maths
  • NCERT Solutions for Class 11 Physics
  • NCERT Solutions for Class 11 Chemistry
  • NCERT Solutions for Class 11 Biology
  • NCERT Solutions for Class 10 Maths
  • NCERT Solutions for Class 10 Science
  • NCERT Solutions for Class 9 Maths
  • NCERT Solutions for Class 9 Science
  • CBSE Classes

  • CBSE Class 5 Questions
  • CBSE Class 6 Questions
  • CBSE Class 7 Questions
  • CBSE Class 8 Questions
  • CBSE Class 9 Questions
  • CBSE Class 10 Questions
  • CBSE Class 10 Maths Questions
  • CBSE Class 11 Commerce Questions
  • CBSE Class 11 Engineering Questions
  • CBSE Class 11 Medical Questions
  • CBSE Class 12 Commerce Questions
  • CBSE Class 12 Maths Questions
  • CBSE Class 12 Engineering Questions
  • CBSE Class 12 Medical Questions
  • BOARDS

  • CBSE
  • ICSE
  • NCERT
  • IGCSE
  • Andhra Pradesh
  • Bihar
  • Gujarat
  • Jharkhand
  • Karnataka
  • Kerala
  • Madhya Pradesh
  • Maharashtra
  • Punjab
  • Rajasthan
...