Code Decoration: The End

For everything that's not in any way related to PureBasic. General chat etc...
scriptmaster
User
User
Posts: 15
Joined: Fri Mar 13, 2009 3:13 pm
Location: Chennai, India

Code Decoration: The End

Post by scriptmaster »

I use the following to wrap PB codeblocks:

Code: Select all

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;{;;;;;;;;;;;;;;               INCLUDES                  ;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

IncludeFile "Common.pb"
IncludeFile "EventProcs.pb"

;};;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

And I use the following at the end of my event loops:

Code: Select all

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;     ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;                               ;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;                                               ;;;;;;;;;;;;;
;;;;;;;;                                                         ;;;;;;;;
;;;;;                                                               ;;;;;
;;;                                                                   ;;;
;;                                                                     ;;
;                                 The                                   ;
                                  End                                    
;                                                                       ;
;;                                                                     ;;
;;;                                                                   ;;;
;;;;;                                                               ;;;;;
;;;;;;;;                                                         ;;;;;;;;
;;;;;;;;;;;;;                                               ;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;                               ;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;     ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Love PB!!! :D


Hope this helps! :D
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Post by Kaeru Gaman »

a long time ago, in a galaxy far far away, I used fancy stuff like this:

Code: Select all

; #######################################################
;
;    ## ##     ##   ##    ##    ####  ##  ##     ## ## 
;     ###      ### ###   ####    ##   ### ##      ###  
;   #######    #######  ##  ##   ##   ######    #######
;     ###      ## # ##  ######   ##   ## ###      ###  
;    ## ##     ##   ##  ##  ##  ####  ##  ##     ## ## 
; 
; #######################################################
but it is a waste of time id it isn't generated automatically.
nowadays, one or two lines full of asterisks are fully sufficent.

Code: Select all

;*******************************************************
;*** PROCEDURES
;*******************************************************


;*******************************************************
;*** MAIN LOOP
;*******************************************************
PS:
I think is is rather some Offtopic-Talk than some "Tricks 'n' Tips"...
oh... and have a nice day.
User avatar
Rings
Moderator
Moderator
Posts: 1435
Joined: Sat Apr 26, 2003 1:11 am

Post by Rings »

Kaeru Gaman wrote:PS:
I think is is rather some Offtopic-Talk than some "Tricks 'n' Tips"...
done
SPAMINATOR NR.1
Tipperton
Addict
Addict
Posts: 1286
Joined: Thu Jun 19, 2003 7:55 pm

Post by Tipperton »

Code: Select all

;--------------------------------------------------------------------- 
; PROCEDURES
<code>

;--------------------------------------------------------------------- 
; MAIN LOOP
<code>
Works for me...
Franky
Enthusiast
Enthusiast
Posts: 213
Joined: Sat Apr 26, 2003 2:58 pm

Post by Franky »

Comments? What is a comment? Was hard to right, should be hard to read, too 8)
Give Up everything but trying!
User avatar
X0r
Enthusiast
Enthusiast
Posts: 147
Joined: Tue May 01, 2007 3:49 am
Location: Germany

Post by X0r »

but only for code bandits :twisted:
Mistrel
Addict
Addict
Posts: 3415
Joined: Sat Jun 30, 2007 8:04 pm

Post by Mistrel »

I use comments for comments and use multiple files to organize what groups of functions do what, similar to breaking a project up into classes. I use one file "inc.Prototypes.pb" in "Main.pb" which contains global structures, includes, and prototypes.
User avatar
GeoTrail
Addict
Addict
Posts: 2794
Joined: Fri Feb 13, 2004 12:45 am
Location: Bergen, Norway
Contact:

Post by GeoTrail »

So that's the reason you guys can spend 2 hours writing an empty if else end block hehehe
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!
User avatar
Inner
PureBasic Expert
PureBasic Expert
Posts: 714
Joined: Fri Apr 25, 2003 4:47 pm
Location: New Zealand

Post by Inner »

Try this;

http://search.cpan.org/~jasonk/DBICx-Au ... AutoDoc.pm

About as close as I can find to the good'ol Amiga Includes & Autodocs format.
User avatar
Hroudtwolf
Addict
Addict
Posts: 803
Joined: Sat Feb 12, 2005 3:35 am
Location: Germany(Hessen)
Contact:

Post by Hroudtwolf »

Yeah. Is it a new style named "bollywood coding"?
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Post by Kaeru Gaman »

no, this is commending, not coding...

"Bollywood Coding" would mean, that the main variables take four minutes to dance and sing before you can erase them...
oh... and have a nice day.
User avatar
Hroudtwolf
Addict
Addict
Posts: 803
Joined: Sat Feb 12, 2005 3:35 am
Location: Germany(Hessen)
Contact:

Post by Hroudtwolf »

I would like it ^^
User avatar
Joakim Christiansen
Addict
Addict
Posts: 2452
Joined: Wed Dec 22, 2004 4:12 pm
Location: Norway
Contact:

Post by Joakim Christiansen »

Image
...
Image

This is what I love about the PureBasic IDE... :D No more mess!
I like logic, hence I dislike humans but love computers.
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Post by Kaeru Gaman »

oh... looks cool.
you added ;- as foldstard and ;_ as foldend, to achieve this?
nice idea!
oh... and have a nice day.
User avatar
Joakim Christiansen
Addict
Addict
Posts: 2452
Joined: Wed Dec 22, 2004 4:12 pm
Location: Norway
Contact:

Post by Joakim Christiansen »

Kaeru Gaman wrote:oh... looks cool.
you added ;- as foldstard and ;_ as foldend, to achieve this?
nice idea!
Indeed, this is so I can get it marked in the "tools panel" too. Else I just use the default ;{ and ;} :)
I like logic, hence I dislike humans but love computers.
Post Reply