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 7060875
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T04:24:19+00:00 2026-05-28T04:24:19+00:00

I’m building a site with Ruby on Rails 3.1 where I also need to

  • 0

I’m building a site with Ruby on Rails 3.1 where I also need to have PDF versions of certain data. For this I use Prawn (master) with the Prawnto gem. Works really well. However, there is just this one thing that I cannot see how to get done.

The PDF contains tabular data where I would like to change the cell border styles differently to better visualize certain parts. At the moment I have rows that can be single or multiple grouped together. The single line or group should have a solid border around it to show that this is a group.

 -----------------------------------------------------------------
| Row 1                                                           |
 -----------------------------------------------------------------
 -----------------------------------------------------------------
| Row 1                                                           |
|                                                                 |
| Row 2                                                           |
 -----------------------------------------------------------------

Now what I’d like is to have a dashed/dotted line between row 1 and row 2 in the second group. I’d also need to in certain cases have vertical (left/right) dashed/dotted borders in cells.

 -----------------------------------------------------------------
| Row 1                                                           |
|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -|
| Row 2                                                           |
 -----------------------------------------------------------------

I’ve been trawling the web for examples, but no luck at all. How can this be done? The only thing I can do is to dash all borders in the table, but this is not what I want.

pdf.dash 4, :space => 3
pdf.table data

I would like to be able to set the border styles individually for each cell, but also in a way where a cell can have different styles for different borders. I.e. top is solid and bottom is dashed.

Any suggestions or help how I can achieve this? Would a text box or bounding box help instead of using a table?

Thanks in advance!

  • 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-05-28T04:24:20+00:00Added an answer on May 28, 2026 at 4:24 am

    No, this is not possible currently.

    I have made a fork of prawn and added the necessary code that allows to mix solid, dashed and dotted cell borders in a table.

    You can find the fork here.

    Example usage when creating a table cell:

    :border_lines => [:solid, :dotted, :dashed, :dashed]
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I have a French site that I want to parse, but am running into
We're building an app, our first using Rails 3, and we're having to build
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
I have thousands of HTML files to process using Groovy/Java and I need to
I have this code to decode numeric html entities to the UTF8 equivalent character.
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have just tried to save a simple *.rtf file with some websites and

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.