Amiga-Development

Please login or register.

Login with username, password and session length
Advanced search  

News:

Created for developers of all Amiga camps

Pages: [1] 2 3 ... 10
 1 
 on: February 23, 2017, 05:24:06 PM 
Started by Zendarion - Last post by Zendarion
So this is what I am after this time. I am new at PortablE and may have basic questions.

Define a string
A string value
An array
Populate the array with random string values

I think I am a bit confused, for now, when it comes to arrays and PortablE. By the way, the hint you gave me on the other thread was great. Worked perfectly and in a way everything seems so obvious when I see it like that.

The code is not mine but I would do it like this in C# and now I would like to have a go at it in PortablE

private static string CreateRandomPassword(int passwordLength)
{
 string allowedChars = "abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNOPQRSTUVWXYZ0123456789!@$?_-";
 char[] chars = new char[passwordLength];
 Random rd = new Random();

 for (int i = 0; i < passwordLength; i++)
 {
  chars = allowedChars[rd.Next(0, allowedChars.Length)];
 }
 return new string(chars);
}

// Hans

 2 
 on: February 16, 2017, 10:55:53 AM 
Started by Zendarion - Last post by Zendarion
Have a few questions

1. When I use addTick(), how can I get the text that describe the tick on the right side instead of left? Just to choose sides?

2. When creating a GUI, to have a fixed size at start, like 640*480, Fullscreen, 1920*1080

3 I can only resize the window horizontal and not vertical. I have seen some example programs you have made and some can do both. How do I do that?

4. I used a button to show a picture but doesnt seem right to use a button and GHOST it for a picture. And can a picture stretch out is the application is resized? Didnt send the picture I use.

5. Is there a way to get a textbox with tiny up and down arrows to increase a numerical value?

6. Is there something like try catch in PortableE?

Code below and the button is just a copy and paste from something else I did and has no function.
--------------------

MODULE 'std/cGui', 'std/cApp', 'std/cPath'
PROC main()
DEF win:PTR TO cGuiWindow, button:PTR TO cGuiButton
DEF item:PTR TO cGuiItem, quit:BOOL
DEF outPut:PTR TO cGuiText, passLength:PTR TO cGuiNumberString
DEF uclTick:PTR TO cGuiTick, lclTick:PTR TO cGuiTick
DEF temp:ARRAY OF CHAR

CreateApp().build()

win := CreateGuiWindow('PassGen v1.0')

win.beginGroupVertical('')
win.addButton('').initPic('pass.jpg').setGhosted(TRUE)


win.beginGroupHorizontal('Select Character Set')
        win.beginGroupVertical()
                uclTick := win.addTick('Uppercase Letters')
                lclTick := win.addTick('Lowercase Letters')
        win.endGroup()

        win.beginGroupVertical()
                uclTick := win.addTick('Uppercase Letters')
                lclTick := win.addTick('Lowercase Letters')
        win.endGroup()
win.endGroup()

        win.beginGroupVertical()
                outPut := win.addText('Your new password').setState('')
                passLength := win.addNumberString('Enter Password Length', 0, 10)
                 button := win.addButton('OK').initPic('tbimages:/ok_g').setGhosted(FALSE)
        win.endGroup()
win.endGroup()
win.build()

quit:=FALSE
REPEAT
        item:=WaitForChangedGuiItem()
        IF item = NIL
                IF win.getCloseRequest() THEN quit := TRUE

        ELSE IF item = button
                IF StrCmp('Hans', temp)
                        outPut.setState('Hej Hans')
                ELSE
                        outPut.setState('Du är inte Hans, arghhh!!!')
                ENDIF
        ENDIF
UNTIL quit
win.close()

ENDPROC

 3 
 on: February 11, 2017, 06:07:49 PM 
Started by magorium - Last post by magorium
Since another thread already discussed the basics of C, and some 'hidden' specifics that the language confronts you with i got into a bit of a problem with regards to translating hively player to Pascal.

I've looked at my 'port' a numerous amount of times now and, i simply fail to see where i go wrong. Most probably i have interpreted that the c-code does something but in fact does something different then i was expecting. As can be read from that earlier mentioned thread, that is something i am still struggling with (even after all these years).

The wonderful results can be found here.

I would be obliged if someone with more c knowledge (and preferably a bit of Pascal as well) would be able to point me a bit into the right direction. One word of warning though as the code is a bit tedious and long winded. I've looked at the code for so long that i can't even distinguish spaces from numbers anymore  ;D

In case wondering, i used the hvl2wav sources. That way i could use the original c produced executable to generate a wav file and see what the Pascal translated code produced, compare the wav files to see if both codes produced the same -> my code goes a bit off at some of the effects (i was even unable to determine which effect(s)).

In the end i would like to add the ahi/wav back-end to be used in a player or all platforms (even though the c code can be used to do the same).

regards,

 4 
 on: February 07, 2017, 05:19:04 PM 
Started by ALB42 - Last post by ALB42
FreePascal for Amiga got it's own Subforum, so Welcome.

I hope to establish this as a central discussion point for all FreePascal@Amiga users.
And Amiga stands here for Amiga OS3, Amiga OS4, AROS and MorphOS.

One Request please let the war between the Platforms out.
Currently there are not much differences between the 4 Platforms, and I'm working on it to make it even smaller.

 5 
 on: February 05, 2017, 05:47:45 PM 
Started by ALB42 - Last post by ALB42
Because I guided some people to this Forum to discuss FreePascal on Amiga Systems.
I will start with a simple message here, maybe we can use this Forum as platform independent Forum to discuss FreePascal stuff.

So if you use/want to use/interested in Pascal on any of the Amiga Systems answer here, what you do/what you would like todo, some questions, ideas... everything is interesting (even a "Hello world" :-P)

 6 
 on: February 05, 2017, 05:44:45 PM 
Started by ALB42 - Last post by ALB42
Does anyone know a source or maybe even a library to show an 24bit Image on an AGA/ECS Screen (even on Workbench), so in principle to convert 24Bit to the current screen Palette + obtaining the needed pens.

 7 
 on: December 18, 2016, 03:44:01 PM 
Started by adminZRt75 - Last post by adminZRt75
    

680x0
68020
68030
68040
68060
ab3support
alib
agl
agle
aglsmap
aglu
aglut
akccplus
als
amarquee
amigaguide
amigaini
amigametaformat
amisslmaster
amos
anaiisresident
arexxport
aros
arosc
arosmesa
arossupport
asl
asyncio
avcodec
battclock
bfbplaymaster
bgui
BigNum
bitmap
blademp3
BlueRibbon
boards
bootloader
bullet*
bsdsocket*
BTIsam
bullet
bzip2
bz2
bz2_au
cag
calculus
camd
catharsis
cclib
cddb
cdplay
cdplayer
chunky
chunkyppc
codesets
commodities
coolimages
cgxbootpic
cgxvideo*
codecs
commodities
configfile
configio
console
coolimages
crc
cybergraphics
database
datatypes
date
dbplayer
dctv
debug
destracker
dfunc
dicecache
digibooster3
din
disassembler
diskfont
dmxemul
dopus
dopus5
dos
dospath
ds
dtimage
easyaudio
easyfft
easygadgets
eagui
easylife
easyrexx
efi
egl
Exec
expansion*
expat
expat_au
explode
extra
fame
feelin
fifo
fileid
filevirus
foxgui
fpl
freedb
freetype2
gadget
gadoutline
gadtools
gadutil
gallium
gamesupport
garshnelib
geclass
gengine
ggdebug
giraffe
gfx3d
gl
glu
graphics
graphics hidd
graphics3d
gtdrag
gtlayout
guienv
guifront
guigfx
guitools
gwin
hidd hidd
hostlib
hpet
hvlplay
hyperlayers
icon
iconobject
icqsocket
id3tag
identify
Idm
iff
iffparse
ilbm
image
imagepool
input
intuition
io
iptcdata
ixemul
ixemul_poolmem
ixnet
javascript
jfif
joinOS
joystick
jpeg
jpeg_au
js_tools
kbd hidd
kd_freq
kernel
keymap
kms
layers
lcms2
lcms2_au
lh
listtools
locale
locator
lowlevel
lucyplay
magicasl
mathffp
mathieeedoubbas
mathieeedoubtrans
mathieeesingbas
mathieeesingtrans
mathtrans
mcpgfx
mcpsupport
memoptimizer
memory
memorymanage
mesa
mesa3dgl
meshwriter
mhimasstd
mhimdev
Microbe3D
midi
misc
mmu
modify
modifyle
mouse hidd
mpega
mpgui
mpimage
mrq
mtool
muiconfig
muigfx
muihelp
muilocale
muilowlevel
muimaster
muipop
muirexx
muiscreen
muispecial
muitoolkit
multireq
mysticview
mxm
netsupport
neuralnet
newicon
node
nonvolatile
notifyintuition
nvdisk
ObjectiveGadTools
oop
openpci
openurl
oxmaster
parse
partition
pccard
pci hidd
pdalink
png
pngflux
pgp
pixman
player61
playsid
png
pngalpha
pngflux
png_au
pointer
Pony3D
popupmenu
poseidon
posixc
post
powerpacker
ppipc
preferences
processor
prometheus
proof
provision
ptplay
ptreplay
queue
quickdos
quickhelp
quicktools
rainbow
random250
realtime
rebol
regex
regina*
reqtools
remote
render
req
reqchange
reqtools
ressourcetracking
rexx_asl
rexx_dos
rexx_exec
rexx_icon
rexx_intuition
rexx_math
rexx_misc
rexx_reqtools
rexx_stem
rexxidentify
rexxmathlib
rexxmoos
rexxsupport
rexxsyslib
rexxtricks
rmh
ros
rtgextra
rxasl
rxtoolkit
rxwiz
scalosgfx
screenfool
screennotify
SDL
SetPatch
shadow
simpledt
skiplist
sndfile
soft3d
sqlite3
ss
Stc
stdc
stdcio
storage
strings
superplay
sysinfo
taglist
task
tdrender
ted
thread
timer
tool
translator
triton
tritonrexx
ttengine
ttf
type1
ucode
umssupport
uni
unitconv
unixio hidd
unpack
usergroup
utility
uuid
vapor_toolkit
vega
version
virtualmem
vlab
vmemory
voice
Warp3D
warpsdl
wbstart
wild
Wizard
workbench
xadmaster
xemrip
xfdmaster
xmplayer
xpkmaster
xprzmodem
xvs
z
z1
z_au
zlib
   
   
   

Comparation AROS

 8 
 on: December 18, 2016, 03:33:01 PM 
Started by adminZRt75 - Last post by adminZRt75
    

hvlplay library
   
   

Hivelytracker player routine

Archive included in added_components/hivelyplay

Reference:

HVL_Decode
HVL_GetAttr
HVL_FreeTune
HVL_InitSubSong
HVL_LoadTune
HVL_Seek
HVL_SetAttrsA
   

 9 
 on: December 18, 2016, 03:31:59 PM 
Started by adminZRt75 - Last post by adminZRt75
    

guigfx library
   
   

application layer for pixel graphics. C includes included.

Archive included in added_components/guigfxlib

Reference:

AddPaletteA
AddPictureA
AddPixelArrayA
ClonePictureA
CreateDirectDrawHandleA
CreatePenShareMapA
CreatePictureBitmapA
CreatePictureMaskA
DeleteDirectDrawHandle
DeletePenShareMap
DeletePicture
DirectDrawTrueColorA
DoPictureMethodA
DrawPictureA
GetPictureAttrsA
IsPictureA
LoadPictureA
LockPictureA
MakePictureA
ObtainDrawHandleA
ReadPictureA
ReleaseDrawHandle
RemColorHandle
UnlockPicture
AddPaletteA

 10 
 on: December 18, 2016, 03:31:15 PM 
Started by adminZRt75 - Last post by adminZRt75
    

guifront library
   
   

it peovides means of creating fully font sensitive graphic use interfaces with minimum effort. Founded on gadtools.

Archive included in added_components/guifront

Includes for C

Reference:

GF_CreateGUIAppA
GF_DestroyGUIApp
GF_CreateGUIA
GF_DestroyGUI
GF_GetGUIAttrA
GF_SetGUIAttrA
GF_GetGUIAppAttrA
GF_SetGUIAppAttrA
GF_GetIMsg
GF_Wait
GF_ReplayIMsg
GF_SetAliasKey
GF_BeginRefresh
GF_EndRefresh
GF_SetGadgetAttrsA
GF_GetGadgetAttrsA
GF_LockGUI
GF_UnlockGUI
GF_LoadPrefs
GF_SavePrefs
GF_LockPrefsList
GF_UnlockPrefsList
GF_FirstPrefsNode
GF_NextPrefsNode
GF_CopyAppID
GF_GetPrefsAttrA
GF_SetPrefsAttrA
GF_DeletePrefs
GF_NotifyPrefsChange
GF_EndNotifyPrefsChange
GF_AslRequest
GF_EasyRequestArgs
GF_ProcessListView
   

Pages: [1] 2 3 ... 10