I want to get back into coding...FB starter's help please? - Printable Version +- Qbasicnews.com (http://qbasicnews.com/newforum) +-- Forum: General (http://qbasicnews.com/newforum/forum-6.html) +--- Forum: General/Misc (http://qbasicnews.com/newforum/forum-18.html) +--- Thread: I want to get back into coding...FB starter's help please? (/thread-8559.html) |
I want to get back into coding...FB starter's help please? - Zack - 12-14-2005 Hey gang. About a year ago, I sort of stopped posting here very often. This coincided with the gradual stop of my coding (I continued a bit longer with web design, php, html, etc., but that stopped too). Now, I want to get back into coding. I was never very good at it before, particularily when it came to graphical stuff, but I've learned more math and logic and general stuff like that. So, I'm getting that itch, and I think I'll start off in FB, seeing as everyone here seems to like it a lot. Now I need a few things cleared up: 1) What is the difference between FB and QB? 2) Will all functional QB code work identically under the FB compiler? 3) Is there a tutorial or some docs to help me learn the new functions, commands, etc.? 4) A lot of the programs written in FB appear to be Windows apps...so I assume that FB compiles everything for a 32-bit Windows (windowed or not) environment? Questions 1 and 3 are most important. Hope you can help me out. Zack I want to get back into coding...FB starter's help please? - Sterling Christensen - 12-14-2005 Here's the official FB wiki: http://www.freebasic.net/wiki/wikka.php?wakka=DocToc 1. Major differences: More features: (inline asm, pointers, high res 32 bit gfx, etc) Creates 32 bit executables (no 640K limits), INTEGER type is 32 bit 2. Will QB code work: Yes, even graphical programs (SCREENs 0-13). With a few small exceptions: "SLEEP 1" waits one millisecond, not one whole second Can't use SCREEN for page flipping, use SCREENSET instead "FB compiles everything for a 32-bit Windows"? Not just Windows. Linux and DOS (32 bit only, no support for 16 bit executables) too. I'm pretty sure QB Express Magazine has published some QB->FB tutorials: http://www.petesqbsite.com/sections/express/express.shtml EDIT: Hmmm... there are some FB tuts for complete beginners, but I don't see anything for QB veterans. I'll keep looking. EDIT: micro -> milli :oops: I want to get back into coding...FB starter's help please? - Zack - 12-14-2005 Hey thanks Sterling, I'll check out those links right away. I want to get back into coding...FB starter's help please? - Z!re - 12-14-2005 It's millisecond, not micro.. Anywyas, I dont think you'll have any problems Zack, think of it as QB.. but stronger, better, faster I want to get back into coding...FB starter's help please? - NecrosIhsan - 12-14-2005 Hey Zack! Wb man...we missed ya around here. Well okay, at least I did. I want to get back into coding...FB starter's help please? - Zack - 12-14-2005 Z!re: Cool. But where do I learn to use all that stuff, like how to make a Windows-based GUI, etc.? Necros: OK, NecrosIhsan doesn't ring a bell...are you adosorken? In any case, hey. I want to get back into coding...FB starter's help please? - Z!re - 12-15-2005 Quote:Z!re: Cool. But where do I learn to use all that stuff, like how to make a Windows-based GUI, etc.?I have no idea where you learn all that I tried, but the windows API is confusing and I dont like it. Necros is ado ya And I forgot to say welcome back =) I want to get back into coding...FB starter's help please? - stylin - 12-15-2005 Quote:... where do I learn to use all that stuff, like how to make a Windows-based GUI, etc.?Lots of places. Microsoft even has a website dedicated to such things, no less. http://msdn.microsoft.com is a good place to start, specifically, http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/winui/windowsuserinterface/windowui.asp The Windows API isn't so much confusing as it is monotonous. You write lots and lots of repetitive, or boilerplate, code. I want to get back into coding...FB starter's help please? - Zack - 12-15-2005 OK, after a bit of time spent getting reacquainted with the BASIC syntax, and some research on the FB wiki site, I came up with a very rudimentary drawing program. The code is messy, redundant in places, and very simple. And it has two bugs. First, why doesn't the old QBASIC trick for detecting arrow keys work? I mean the old IF k$=CHR$(0) + CHR$(77) THEN rightArrowPress=1 thing. I tried it, it didn't work. Secondly...when I draw in the program, if I move the mouse cursor too fast across the canvas, instead of drawing a smooth line, it draws a broken line. Now I suspect it's because the mouse cursor moves past the spot where you want to draw before the code registers that it was ever there. But I might be wrong. In either case, I don't know how to fix it. Can anyone help? Here's the code: Code: 'CANVAZZ.BAS I want to get back into coding...FB starter's help please? - stylin - 12-15-2005 Quote:First, why doesn't the old QBASIC trick for detecting arrow keys work? I mean the old IF k$=CHR$(0) + CHR$(77) THEN rightArrowPress=1 thing. I tried it, it didn't work.http://www.freebasic.net/forum/viewtopic.php?t=1807 Quote:Secondly...when I draw in the program, if I move the mouse cursor too fast across the canvas, instead of drawing a smooth line, it draws a broken line. Now I suspect it's because the mouse cursor moves past the spot where you want to draw before the code registers that it was ever there. But I might be wrong. In either case, I don't know how to fix it. Can anyone help?You'll have to draw a line from point to point. Which in your case means drawing a 3-pixel thick line from point to point. |