Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Calculator
#1
[Image: Calculator-by-Sierra-Ken.jpg]

Two years ago I made this calculator which has animated buttons using your mouse or keyboard. Today I decided to add the Copy and Paste buttons to it. Before you could click your number or do Ctrl-C to copy it in the clipboard but I never added a way to paste a clipboard number into your screen until today. Smile You can copy from any program and paste it to the calculator, or copy from the calculator and paste it to itself. Tell me what you think, thanks.

(Code deleted with an update below.)
Reply
#2
I added a 17 digit limit to the Paste, if it's beyond that the number will revert to 0.
Reply
#3
interesting. thank you for sharing this code. it would be necessary to enlarge the display fonts and there is a latency time when clicking.
Reply
#4
I've been using your button beveling algorithm ever since you first posted the calculator. I just like that look.
DO: LOOP: DO: LOOP
sha_na_na_na_na_na_na_na_na_na:
Reply
#5
(07-25-2022, 09:34 AM)Coolman Wrote: interesting. thank you for sharing this code. it would be necessary to enlarge the display fonts and there is a latency time when clicking.

change the delay in the press handling code and that stops being a problem. 
It's "_delay .25"   and the lag vanished on my system with "_delay .03"
Reply
#6
This is probably causing problems too:
Code: (Select All)
    Do While _MouseInput
        mousex = _MouseX
        mousey = _MouseY
        mouseLeftButton = _MouseButton(1)
    Loop


The way to poll the mouse is
While _Mouseinput: Wend  ' poll mouse

then
Code: (Select All)
        mousex = _MouseX
        mousey = _MouseY
        mouseLeftButton = _MouseButton(1)
b = b + ...
Reply
#7
(07-25-2022, 01:05 PM)James D Jarvis Wrote:
(07-25-2022, 09:34 AM)Coolman Wrote: interesting. thank you for sharing this code. it would be necessary to enlarge the display fonts and there is a latency time when clicking.

change the delay in the press handling code and that stops being a problem. 
It's "_delay .25"   and the lag vanished on my system with "_delay .03"

indeed. thank you
Reply
#8
Thanks for your input guys. I changed the font to Arial font size 18 and 14 for the Help Page. When I tried the _DELAY at .03 it often was doubling the number when I clicked a button, or tripling, or more. So I it seems to work fine with me at .2. I did what B+ said and changed the mouse commands and it seems to work a little bit better. B+, I've always gotten that mouse code from the Wiki pages. But I will try to use While/Wend instead, thanks. I also added some better code to keep the limit of digits from going off the screen. 
Here is the update: 

(Code deleted again, go to Page 2 for the update.)
Reply
#9
The program is great and the graphics are excellent.
I see the point of such programs in that you learn a lot and that it's fun. You learn the most when you have fun.

I once wrote a program about financial mathematics in QuickC 2.5, it ran under MS-DOS in Win95. Later I realized parts of it in HTML. Since it was an intranet with IE as the browser, I could use VBScript. It was the better script language, unfortunately MS wasn't as violent as in other things. - Fucking javascript!

Unfortunately I couldn't use the Form-2-Controls (ActiveX) they looked as real as in the "Calculator". Good program!



[Image: Rentenraten2022-07-25.jpg]

I need now . . . what . . .  Tongue
Reply
#10
Thanks! Wow I never really got into C much myself, mostly always stuck with different variations of BASIC since the 80's. Although I did make many websites in html and a little bits of C, Visual Basic, etc.
Reply




Users browsing this thread: 13 Guest(s)