It is currently Tue Jan 19, 2021 7:46 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 25 posts ]  Go to page Previous  1, 2
Author Message
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Sat Mar 05, 2016 7:30 pm 
Offline
Always Here
Always Here
User avatar

Joined: Thu Jun 24, 2004 2:44 pm
Posts: 5756
Location: Berlin - Germany
Use the scintilla documentation: http://www.scintilla.org/ScintillaDoc.html#Printing

_________________
PureBasic 5.71 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 19.3 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Sat Mar 05, 2016 10:39 pm 
Offline
Addict
Addict
User avatar

Joined: Mon Oct 26, 2015 2:55 am
Posts: 936
Location: UA
Never needed to print code, but I think you can make simple x-platform util this way:
1. Send selected text from IDE to your tool (it is possible by tool command line or Scintilla commands)
2. In your tool use example from "Purebasic\SDK\Syntax Highlighting" to highlight PB code (if you need colored printing)
3. Print results using Printer library

_________________
High hopes * Low expectations


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Sun Mar 06, 2016 11:28 am 
Offline
Addict
Addict

Joined: Wed Nov 12, 2008 5:01 pm
Posts: 1131
Location: Russia
Scintilla supports printing of text. http://www.scintilla.org/ScintillaDoc.html#Printing

_________________
Library XP_Menu_Lib - office menu; HID_Lib - USB Library
Torrent client - pbTorrent (source code); Create driver in PureBasic.


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Mon Mar 07, 2016 5:14 am 
Offline
Enthusiast
Enthusiast

Joined: Wed Feb 29, 2012 8:04 am
Posts: 191
Location: Melbourne, AUS
To print a file I just open the file in my text editor (in my case PSPad - an excellent freeware editor - color formatting etc)


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Mon Mar 07, 2016 11:34 am 
Offline
User
User

Joined: Thu Jan 02, 2014 5:01 pm
Posts: 60
Neil wrote:
To print a file I just open the file in my text editor (in my case PSPad - an excellent freeware editor - color formatting etc)


Much better than copying and pasting. However, I couldn't find a way to have colour formatting. Purebasic isn't one of the standard languages that would allow you to do this. PSPad is indeed an excellent freeware editor.


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Mon Mar 07, 2016 11:58 am 
Offline
Addict
Addict

Joined: Sat Feb 08, 2014 3:26 pm
Posts: 966
Quote:
I couldn't find a way to have colour formatting. Purebasic isn't one of the standard languages that would allow you to do this. PSPad is indeed an excellent freeware editor.

Uses Notepad++ (https://notepad-plus-plus.org/)
Notepad++ is based on Scintilla component like PB so it's easy to use (some) shortcuts

For color formatting:
- Setting > Style configurator > use "AutoIt" as base (autoit use basic syntax)
- Change others style same as PB
- Click Save and close

:wink:


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Tue Mar 08, 2016 12:06 am 
Offline
User
User

Joined: Thu Jan 02, 2014 5:01 pm
Posts: 60
After looking at the various options, i think that the solution below is probably about the best. There are others covered by the link provided by IdeasVacuum, but i couldn't get any of them to print in colour.

http://www.purebasic.fr/english/viewtopic.php?t=38783

It is possible to link Notepad++ or PSPad from the Tools menu, which is slightly quicker than copying and pasting. Again, these don't print totally in colour so there is no great adavantage.

Purebasic is a very good piece of software, but I think it is let down by not being able to print out its code directly from its editor.

__________________________________________________
Link repaired
08.03.2016
RSBasic


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Tue Mar 08, 2016 11:31 am 
Offline
User
User

Joined: Thu Jan 02, 2014 5:01 pm
Posts: 60
I've had another look at PureBasicPrint. Although I couldn't get it to print in colour, it does have its advantages in that you can get at its source code and there is also a useful Microsoft Word file that shows how to configure it, including inserting a VERY useful printer icon on the Toolbar.

http://forums.purebasic.com/english/viewtopic.php?t=38375&start=0&postdays=0&postorder=asc&highlight=


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Tue Mar 08, 2016 12:11 pm 
Offline
User
User

Joined: Thu Jan 02, 2014 5:01 pm
Posts: 60
You may have difficulty getting a download link for PureBasicPrint. Vera kindly provided a link at:
http://www.purebasic.fr/english/viewtopic.php?f=27&t=38375&start=15


Top
 Profile  
Reply with quote  
 Post subject: Re: Hard copy of Purebasic code
PostPosted: Tue Mar 08, 2016 12:40 pm 
Offline
Always Here
Always Here

Joined: Fri Oct 23, 2009 2:33 am
Posts: 6271
Location: Wales, UK
I think Flype's work could form the basis of an official print button in the IDE.

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 25 posts ]  Go to page Previous  1, 2

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye