Search found 95 matches

by mhs
Wed Jul 20, 2016 7:41 pm
Forum: Coding Questions
Topic: Form Designer Bug With GadgetText
Replies: 6
Views: 2244

Re: Form Designer Bug With GadgetText

Keya wrote:If you are using an image gadget make sure you're not drawing the image over your text
With other words, there is no z-order, if you put text gadgets over an image gadget, this will not work.
by mhs
Fri Jul 08, 2016 9:50 am
Forum: General Discussion
Topic: Test and compare purebasic internal function and library
Replies: 6
Views: 3108

Re: Test and compare purebasic internal function and library

This is not a representative test of all use cases, it's just a presentation of some cases...

The true strength of a list is the fast adding and removing of elements when the maximum number of elements is unknown (in the beginning) or varies greatly. In this cases you would use a ReDim() on the ...
by mhs
Thu Jul 07, 2016 8:09 pm
Forum: Coding Questions
Topic: UnuseModule cases
Replies: 2
Views: 1162

Re: UnuseModule cases

I would say this one:

Code: Select all

Procedure example()
  UseModule MTest
  If o
    ProcedureReturn
  EndIf
  UnuseModule MTest
EndProcedure
or if it fits better:

Code: Select all

UseModule MTest
Procedure example()
...
EndProcedure
Procedure example2()
...
EndProcedure
UnuseModule MTest
by mhs
Thu Jul 07, 2016 10:22 am
Forum: Coding Questions
Topic: copymemory bug ???
Replies: 1
Views: 1049

Re: copymemory bug ???

drgolf wrote:

Code: Select all

*mem=AllocateMemory(StringByteLength(string))
No bug, the size for the null terminating character is missing...

Code: Select all

*mem=AllocateMemory(StringByteLength(string) + SizeOf(Character))
by mhs
Wed Jul 06, 2016 9:56 pm
Forum: Coding Questions
Topic: How to vertically center a text gadget to a string gadget?
Replies: 6
Views: 2001

Re: How to vertically center a text gadget to a string gadge

Hmm... what's about the "<hbox>" element with align="center"? Can't it be used for this?
by mhs
Tue Jul 05, 2016 4:44 pm
Forum: General Discussion
Topic: [solved] ResizeImage() on Windows is drawing a border...
Replies: 11
Views: 3884

Re: ResizeImage() on Windows is drawing a border...

Same result here... maybe its the antialiasing of the win api.

ResizeImage with the flag #PB_Image_Raw has no border and it happens only in combination with a transparent background.
by mhs
Sun Jul 03, 2016 8:26 pm
Forum: General Discussion
Topic: Proper database table design?
Replies: 35
Views: 17298

Re: Proper database table design?

Every Record (Child / Node) is assigend to the superior Record (Parent) with the Id (ParentId). So you have the possibility to add, edit, delete, sort and order every (Child-) Record to every time. It's a type of a parent child relationship 1:n on the same table.

A treegadget can be used like that ...
by mhs
Fri Jul 01, 2016 4:12 pm
Forum: General Discussion
Topic: Proper database table design?
Replies: 35
Views: 17298

Re: Proper database table design?

Maybe something like that:

UseSQLiteDatabase()

#db = 0

Structure Category

Id.i

Name.s
Description.s
CreatedOn.i

ParentId.i

EndStructure

Procedure.i InsertCategory(Name.s, Description.s, ParentId.i = 0)

Define.s Query
Define.i Id

; === Insert Statement
Query = "INSERT INTO ...
by mhs
Fri Jul 01, 2016 10:08 am
Forum: General Discussion
Topic: Proper database table design?
Replies: 35
Views: 17298

Re: Proper database table design?

I would choose a slightly different scheme for the ChapterCategories table, to avoid duplicate names and for easier handling with sub categories.


ChapterCategories
Id INT
Name TEXT
ParentId INT
ChapterId INT



DatabaseUpdate(DatabaseHandle.i, "INSERT INTO ChapterCategories (Name, ChapterId ...
by mhs
Wed Jun 08, 2016 2:45 pm
Forum: Announcement
Topic: PureBasic 5.50 final is out !
Replies: 132
Views: 75677

Re: PureBasic 5.50 beta 1 is out

Fred will loose a lot of beginners who don't want or need Unicode.
He will loose more pontential customers than the gains with his
unicode-only "BASIC"-language.
Beginners do not know the difference between ASCII and Unicode. They use the functions of String library without worrying about how it ...
by mhs
Thu May 19, 2016 9:50 am
Forum: General Discussion
Topic: Translated List 0f words [Moved On see last Post]
Replies: 20
Views: 8755

Re: Translated List 0f words

managing the list with different translations and new additions/suggestions etc could get tricky though! i just Edited to add a couple and when i clicked Post mhs's post with translations was already there :)

Yeah that could be tricky :D

Maybe with GitHub and separate language files, for freak ...
by mhs
Thu May 19, 2016 9:11 am
Forum: General Discussion
Topic: Translated List 0f words [Moved On see last Post]
Replies: 20
Views: 8755

Re: Translated List 0f words

Maybe as a kind of CSV List?

Englisch;German

File;Datei
New;Neu
Open;Öffnen
Save;Speichern
Save As;Speichern unter
Import;Importieren
Export;Exportieren
Page Setup;Seite einrichten
Print;Drucken
Print Preview;Druckvorschau
Restart;Neustart
Exit;Beenden

Edit;Bearbeiten
Cut;Ausschneiden
Paste ...