top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

RMagick Annotate - interline spacing and its relation with the font

+2 votes
264 views

RMagick Documentation about interline_spacing mentions - "A numeric value. If positive, inserts additional space between lines. If negative, removes space between lines. The amount of space inserted or removed depends on the font."

The problem is that one can not achieve the exact text as was entered by the user. One can break lines using a small javascript and the entire text is being annotated at the server but the line spacing becomes an issue. As of now its a mere guess to set the interline spacing but as and when the font size changes the rendered text goes for a toss.

There could be an alternative to fix the line-height at the client but there doesn’t seem to be any working equation with the interline spacing.

What could be the possible implementable approaches to address the problem of interline spacing so that one can get the exact text appearance rendered out of RMagick as was entered by the user.

posted Jun 13, 2014 by Suyash Tripathi

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button

Similar Questions
+2 votes

I'd like to remove all existing constraints from an ActiveRecord::Relation and leave the rest in-tact.
I am NOT looking for #unscoped since I would like to keep any joins/order clauses around.

Additionally, I would like to re-use the constraints that were removed in another query, so the ability to call #to_sql on them would be a very nice bonus.

This is the best I've been able to hack together:

Order.where(id: 1).where(id: 2).arel.constraints[0].to_sql
 => "`orders`.`id` = 1 AND `orders`.`id` = 2"

...but that just seems wrong. As far as I can tell #constraints always has one item in it, but I don't know that will always be true.

+1 vote

As per specification if we increase sub carrier spacing then slot duration will be less.
What is the relation between these two parameter, why lot duration is getting reduced?

0 votes

I need to display some charts/graphs based upon user inputs on my web application built using Ruby on Rails.
Are there any charting libraries out there that I could use with ROR for displaying simple bar, line and pie graphs?

...