
TailBite 1.0 Preview, soon in PureProject and PureArea
Moderators: gnozal, ABBKlaus, lexvictory
- netmaestro
- PureBasic Bullfrog
- Posts: 8451
- Joined: Wed Jul 06, 2005 5:42 am
- Location: Fort Nelson, BC, Canada
-
- PureBasic Expert
- Posts: 4229
- Joined: Sat Apr 26, 2003 8:27 am
- Location: Strasbourg / France
- Contact:
He's modifying the procedure SplitFunctions() in Tailbite.pb (you need the tailbite sources for the rest).netmaestro wrote:And where's the rest of it?
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).
- netmaestro
- PureBasic Bullfrog
- Posts: 8451
- Joined: Wed Jul 06, 2005 5:42 am
- Location: Fort Nelson, BC, Canada
ok for the experts :
since PB4.01 fred has changed something that tailbite dislike.
heres the header of a compiled snipped (only a part of it)
now tailbite in the current version compiles ok but when i start purebasic again and want to compile with the new lib i get this error (same as Falko´s) :
Now the enumeration breaks exactly when the
I hope i made it clearer now :roll:
Regards Klaus
since PB4.01 fred has changed something that tailbite dislike.
heres the header of a compiled snipped (only a part of it)
Code: Select all
;
; PureBasic v4.01 (Windows - x86) generated code
;
; © 2006 Fantaisie Software
;
; The header must remain intact for Re-Assembly
;
; Window
; Gadget
; String
; StringExtension
; Misc2
; MemoryExtension
; Memory
; LinkedList
; LinkedListExtension
; Library
; Image
; ImagePlugin
; Font
; FileSystem
; File
; Date
; 2DDrawing
; Object
; SimpleList
; :System
; COMDLG32
; GDI32
; KERNEL32
; USER32
; WINSPOOL
;
format MS COFF
and i made some changes to the TailBite.pb sources just like you wrote Gnozal, the SplitFunctions procedure. (See my post above)---------------------------
PureBasic - Error
---------------------------
Error: The following PureLibrary is missing: :System
---------------------------
OK
---------------------------
Now the enumeration breaks exactly when the
part is reached.; :System
I hope i made it clearer now :roll:
Regards Klaus
Thank you Klaus,
I've compiled TailBite with your changes.
Regards Falko
I've compiled TailBite with your changes.

Regards Falko
Last edited by Falko on Sat Nov 11, 2006 10:10 pm, edited 1 time in total.
For the ones willing to test the new Tailbite version heres the link :
V1.3PR1.8b
http://www.purebasicpower.de/?download= ... taller.exe
V1.3PR1.8b
http://www.purebasicpower.de/?download= ... taller.exe
the extensions by gnozal included?
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.

Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.

@ts-soft : do you mean this post http://www.purebasic.fr/english/viewtop ... &start=390
can you supply these changes
can you supply these changes

yes, this is required by some libs for unicode and threadsafe libs.ABBKlaus wrote:@ts-soft : do you mean this post http://www.purebasic.fr/english/viewtop ... &start=390
can you supply these changes
I use the changed version by gnozal, but i can't found the right link here.
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.

Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.

You mean this?
You can edit this code in 'TailBit.pb' and than load and compile
'TailBite Installer Build.pb'. This is all
Regards Falko
And Unicode??in Line 99 of TailBite.pb wrote:ForEach Parameter()
Select UCase(Left(Parameter(), 5))
Case "/THRD" ; Wish from gnozal
UseThreadOption = 1
Case "/ASKD"
AskDelete = 1
Case "/DONT"
DontMakeLib = 1
Case "/KEEP"
KeepSrcFiles = 1
Case "/QUIE"
QuietMode = 1
Case "/WRIT"
WriteBatch = 1
Case "/HELP"
OpenHelp(PBFolder$+"Help\TailBite.chm", "Reference")
End
Case "/HWND"
hParent = Val(Right(Parameter(), Len(Parameter())-6))
Case "/CHM:"
SetChmName = 1
ChmName$ = Right(Parameter(), Len(Parameter())-5)
EndSelect
Next
You can edit this code in 'TailBit.pb' and than load and compile
'TailBite Installer Build.pb'. This is all

Regards Falko
No, a bit more changes, but i can't find the link. The modified sources a here:
http://ts-soft.eu/dl/modifiedsources.zip
http://ts-soft.eu/dl/modifiedsources.zip
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.

Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.

Update is up and running
: TailBite V1.3PR1.8c http://www.purebasicpower.de/?download= ... taller.exe

@ABBKlaus : Can you try this ?
Code: Select all
;/ PureBasic 4.0 / Droopy 06/11/06
;/ Oublié que ProcedureDLL.l --> Le .l foutait la merde
;/ Pas pensé que passage d'un pointeur foutait la merde (*toto)
;/ Gestion des paramètres optionnels si précédés de paramètres non optionnels
;{/ Enumerations
Enumeration ;/ Zone Fichier
#Read
#Write
#DebutZone
#DansZone
#FinZone
#HorsZone
EndEnumeration
Enumeration ;/ Zone de Procédure
#Inconnu
#Variable
#Valeur
#Commentaires
EndEnumeration
;}
Structure DetailProcedure
Optionnel.l
NomVariable.s
Valeur.s
EndStructure
Global NewList Proc.DetailProcedure(), ContenuProcedure.s
Procedure InsertionTBProcedure(Ligne.s)
ClearList(Proc())
;/ Mise en forme de la ligne
Ligne=LTrim(RTrim(Ligne))
;/ Extraction du Nom de la procedure
NomProcedure.s=StringField(Ligne,2," ")
NomProcedure=LTrim(RTrim(StringField(NomProcedure,1,"(")))
;/ Regarde si .? est indiqué après ProcedureDLL et si oui le mémorise dans une variable temporaire
If Mid(Ligne,13,1)="."
Type.s=Mid(Ligne,13,2)
Else
Type=""
EndIf
;/ Garde juste les paramètres
Ligne.s=Right(Ligne,Len(Ligne)-14-Len(NomProcedure)-Len(Type))
Ligne.s=LTrim(RTrim(Ligne))
Zone=#Inconnu
For n=1 To Len(Ligne)
c.s=Mid(Ligne,n,1)
a=Asc(c)
Select Zone
Case #Inconnu
If (a>64 And a<91) Or (a>96 And a<123) Or a=42 ;/ C'est un nom de variable ou *
AddElement(Proc())
Proc()\NomVariable+c
Zone=#Variable
ElseIf c=")"
Zone=#Commentaires
EndIf
Case #Variable
Select c
Case ")"
Zone=#Commentaires
Case ","
Zone=#Inconnu
Case " "
Case "="
NbParaOptionnels+1
Proc()\Optionnel=1
Zone=#Valeur
Default
Proc()\NomVariable+c
EndSelect
Case #Valeur
If a=34 ;/ Détermine si je rentre ou sort d'une zone de guillemet
If ZoneGuillemet=1
ZoneGuillemet=0
Else
ZoneGuillemet=1
EndIf
EndIf
If ZoneGuillemet=1
Proc()\Valeur+c
Else
Select c
Case ","
Zone=#Inconnu
Case ")"
Zone=#Commentaires
Default
Proc()\Valeur+c
EndSelect
EndIf
Case #Commentaires
Commentaires.s+c
EndSelect
Next
Commentaires=LTrim(RTrim(Commentaires))
Commentaires=LTrim(Right(Commentaires,Len(Commentaires)-1))
If NbParaOptionnels
;- Il y a des paramètres optionnels
; Ecriture de la déclaration
Temp.s="Declare"+ Type+" "+NomProcedure+Str(NbParaOptionnels+1)+"("
ForEach Proc()
Temp+Proc()\NomVariable
If ListIndex(Proc())<CountList(Proc())-1
Temp+"," ; Ajoute une virgule uniquement si necessaire entre chaque variable
EndIf
Next
Temp+")"
WriteStringN(#Write,Temp)
For n= 0 To NbParaOptionnels
; Ecrit le nom de la procédure
Temp.s=#crlf$+"ProcedureDLL"+Type+" "+NomProcedure
; Ecriture du N° de la procédure
If n
Temp+Str(n+1)
EndIf
Temp+ "("
; Ecrit juste les paramètres necessaires de la procédure
For i= 0 To CountList(Proc())-NbParaOptionnels+n-1
SelectElement(Proc(),i)
Temp+Proc()\NomVariable
If i<CountList(Proc())-NbParaOptionnels+n-1
Temp+"," ; Ajoute une virgule uniquement si necessaire entre chaque variable
EndIf
Next
; Finalise la ligne de ProcedureDLL en y ajoutant les commentaires
Temp+")"
If Commentaires<>""
Temp+" ; "+Commentaires
EndIf
WriteStringN(#Write,Temp)
If n=NbParaOptionnels
; Ecriture du contenu de la procédure
WriteStringN(#Write,ContenuProcedure)
Else
; Ecriture de l'appel à la procédure principale
Temp2.s=" "+NomProcedure+Str(NbParaOptionnels+1)+"("
ForEach Proc()
If ListIndex(Proc())> n+CountList(Proc())-NbParaOptionnels-1
Temp2+Proc()\Valeur
Else
Temp2+Proc()\NomVariable
EndIf
If ListIndex(Proc())<CountList(Proc())-1
Temp2+"," ; Ajoute une virgule uniquement si necessaire entre chaque variable
EndIf
Next
Temp2+")"
WriteStringN(#Write,Temp2)
WriteStringN(#Write,"EndProcedure")
EndIf
Next
Else
;- Aucun paramètre optionnels
Temp.s="ProcedureDLL"+Type+" "+NomProcedure+"("
ForEach Proc()
Temp+Proc()\NomVariable
If ListIndex(Proc())<CountList(Proc())-1
Temp+"," ; Ajoute une virgule uniquement si necessaire entre chaque variable
EndIf
Next
Temp+")"
If Commentaires<>""
Temp+" ; "+Commentaires
EndIf
WriteStringN(#Write,Temp)
WriteStringN(#Write,ContenuProcedure)
EndIf
EndProcedure
Procedure TBOP(FileIn.s,FileOut.s,TailbitePath.s,Compile)
;{/ Boucle de lecture du fichier en entrée / Génération du fichier de sortie
CreateFile(#Write,FileOut)
If ReadFile(#Read,FileIn)=0
End
EndIf
ZoneFichier=#HorsZone
While Eof(#Read)=0
Ligne.s=ReadString(#Read)
Temp.s=UCase(LTrim(Ligne))
If Left(Temp,12)="PROCEDUREDLL"
ZoneFichier=#DebutZone
LigneProcedure.s=Ligne
ElseIf Left(Temp,12)="ENDPROCEDURE" And (ZoneFichier=#DebutZone Or ZoneFichier=#DansZone)
ZoneFichier=#FinZone
EndIf
Select ZoneFichier
Case #HorsZone
WriteStringN(#Write,Ligne)
Case #DebutZone
ZoneFichier=#DansZone
ContenuProcedure.s=""
Case #DansZone
If ContenuProcedure=""
ContenuProcedure.s+Ligne
Else
ContenuProcedure.s+#crlf$+ Ligne
EndIf
Case #FinZone
ZoneFichier=#HorsZone
ContenuProcedure+#crlf$+Ligne
InsertionTBProcedure(LigneProcedure)
EndSelect
Wend
;}
CloseFile(#Read)
CloseFile(#Write)
If Compile
RunProgram("TailBite.exe",FileOut,TailbitePath)
EndIf
EndProcedure
; TBOP("c:\Printer_Lib.pb","c:\afficheTBOP.txt","c:\Program Files\PureBasic4\TailBite",#True)
; RunProgram("c:\afficheTBOP.txt","","c:\")