GithubHelp home page GithubHelp logo

sublime2pdf's Introduction

Summary

2pdf to generate a pdf file.

pdf file can be printed

2pdf use:

How to install

  1. Clone or [download] git repo into your packages folder (in ST2, find Browse Packages... menu item to open this folder)
  2. Restart ST2 editor (if required)

Or with Package Control:

  1. Run "Package Control: Add repository" and add https://github.com/fraoustin/Sublime2pdf
  2. Run "Package Control: Install Package" command, find and install 2pdf plugin.
  3. Restart ST2 editor (if required)

How to Use

click menu Selection -> ToPdf

Configure key binding

add the following line to keymap settings

{ "keys": ["ctrl+p"], "command": "to_pdf" }

Configure

stylesheet-code is stylesheet use by rst2pdf for all syntax except for the restructured syntax

stylesheet-rst is stylesheet use by rst2pdf for the restructured syntax

{
"stylesheet-code": "print.style",
"stylesheet-rst": "",
"breaklevel": 0,
"compressed": false
}

License

view license of

rst2.pdf

sublime2pdf's People

Contributors

fraoustin avatar jaman avatar

Stargazers

Yannik Ammann avatar  avatar David Aguilar avatar  avatar Leo Willner avatar Lim Li avatar  avatar Angelo Cork avatar Adelar da Silva Queiróz avatar M avatar jwp fox avatar Paul Reny avatar

Watchers

 avatar James Cloos avatar Jin-Hwa Kim avatar William Falk-Wallace avatar  avatar David Aguilar avatar  avatar

sublime2pdf's Issues

Getting a traceback error when running in Sublime Text 2

Installed the 2pdf plugin. When I have a file open and click Selection->2pdf, I get the following traceback dialog:

Traceback (most recent call last): File "./2pdf.py", line 126, in run File "./2pdf.py", line 168, in _run AttributeError: 'module' object has no attribute 'startfile'

Any suggestions?

Traceback Issue while running 2pdf

when i has a fresh install of 2pdf and started to use it, I met a traceback error.

2pdf's 168 line has been already changed to

if sys.platform.startswith('darwin'): subprocess.call(('open', outfile)) elif os.name == 'nt': os.startfile(outfile) elif os.name == 'posix': subprocess.call(('xdg-open', outfile))

screen shot 2013-11-20 at 14 47 35

Plugin not working on OS X 10.6.x in Sublime 2.0.2

My setup:
Mac OS X 10.6.8
Sublime Text 2.0.2 build 2221

When starting Sublime, this can be found in console log:

Reloading plugin /Users/mity/Library/Application Support/Sublime Text 2/Packages/2pdf/2pdf.py
Traceback (most recent call last):
  File "./sublime_plugin.py", line 62, in reload_plugin
  File "./2pdf.py", line 65, in <module>
    import rst2pdf.createpdf
  File "c:\python\python26\lib\site-packages\rst2pdf-0.93.dev-py2.6.egg\rst2pdf\createpdf.py", line 45, in <module>
  File "c:\python\python26\lib\site-packages\rst2pdf-0.93.dev-py2.6.egg\rst2pdf\opt_imports.py", line 49, in <module>
  File "c:\python\python26\lib\site-packages\reportlab-2.6-py2.6-win32.egg\reportlab\lib\styles.py", line 25, in <module>
  File "/Users/mity/Library/Application Support/Sublime Text 2/Packages/2pdf/libs/reportlab-2.6.zip/reportlab/lib/colors.py", line 43, in <module>
  File "c:\python\python26\lib\site-packages\reportlab-2.6-py2.6-win32.egg\reportlab\lib\utils.py", line 221, in <module>
  File "/Users/mity/Library/Application Support/Sublime Text 2/Packages/2pdf/libs/reportlab-2.6.zip/_rl_accel.py", line 7, in <module>
  File "/Users/mity/Library/Application Support/Sublime Text 2/Packages/2pdf/libs/reportlab-2.6.zip/_rl_accel.py", line 4, in __bootstrap__
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/pkg_resources.py", line 835, in resource_filename
    self, resource_name
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/pkg_resources.py", line 1297, in get_resource_filename
    "resource_filename() only supported for .egg, not .zip"
NotImplementedError: resource_filename() only supported for .egg, not .zip

The command Selection -> To Pdf is kept grayed and cannot be used.

ST 3 Support

Are there any plans to support both ST 2 and 3?

This plugin is awesome!

2pdf package keeps coming back

Hi,

This hijacks command + p which is why I choose not to use it. But it keeps coming back. even though I removed it from the packages folder. Every day it is back again.

Any idea why this is happening?

Question about directory...

Hi, how I can change directory to output?, now is generated but in temp folder, I would like manage the directories where I want to be output, Does it has this option?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.