TweetFollow Us on Twitter

May 90 Mousehole
Volume Number:6
Issue Number:5
Column Tag:Mousehole Report

HyperCard XCMD DB Routines

By Larry Nedry, Contributing Editor

From: Jhannah

Re: Using Copybits()

The structure of a PICT resource is a bit different than a bitmap! You need to create an offscreen bitmap, paint the PICT to that offscreen bitmap, then make your own bitmap’s baseAddr point to the offscreen bitmap’s baseAddr and then you may use CopyBits with your own bitmap.

From: Scope

Re: Text Rotation - HELP!

I thought that it would be simple, but I am stuck. I want to be able to write a vertical (up or down) text string on a Mac. I can easily do it under HALO or GSS on the IBM by simply setting the text rotation to the desired angle and writing away, but I can’t find any related commands in IM I..V. The only solution to providing a rotated object I have ever seen mentioned was in “The Best of MacTutor-I”, which had an algorithm for bitmap rotation. This seems too complicated for such a (seemingly) simple operation. Can it be that the Mac can’t do it? Or did I just miss something. Please help.

[Check out John Olsen’s article in Vol. 4 No. 2 on page 62 for a 90 degree text rotation article (it is also found in the Definitive MacTutor on page 9. The source code is found on disk #29.-ed]

From: Dont

Re: HyperCard XCMD db routines

From that terminal illness Married & Mortgaged. The programming I do get a chance

From one of the above. It must be multiuser and be able to use the Mac as a host.It must be able

Flipping through MacTutor one finds four obvious choices...

1. c-tree from Faircom

2. db_VISTA ||| from Raima

3. Inside Out from Shana Corp.

4. HyperHit from SoftStream.

Items 1-3 are C routines designed for developers and would require XCMD routines. Item 4 is already built for HyperCard. Does anyone have experience with these products? If so, do the perform as advertised. For items 1-3 are there any XCMD implementations?

From: Drunkle

Re: HyperCard XCMD db routines

DonT -- Something you may want to investigate is the XCMD package being marketed by Dan Shafer: HyperFox. Allows opening, reading, updating FoxBASE format data and index files from within HyperCard. Single User commercial license is $75, multi-user and site licensing also priced on a sliding scale. Marketing company is Apricot Press, 277 Hillview Ave., Redwood City, CA 94062. Shafer is available via CompuServe [71246,402], MacNET or AppleLink (DSHAFER). I’ve sent for a copy but haven’t yet received it.

From: Tomt

Re: HyperCard XCMD db routines

I think that several other mainline databases have Hypercard front ends available. You might check on that first before buying one of the products you listed. There was a review of HyBase and HyperHit in this weeks Macweek.

From: Jersquare

Re: Floating Windows

Floating windows “float” over any active window. They are windoids. But lately I have found if I ask for windoids I get advice on WDEF’s I needed to know how to make my windoids work once I had them on the screen.

The rules seem to be these

1. Windoids are always in front of document windows.

2. When you leave the Application (under multifinder) they disappear. That seems to be it really. I needed to know how to make it look like they were always on top, especially when I moved a document window.

From: Rastamon

Re: Floating Windows

Regarding, when floating windows should be hidden:

Although I haven’t (yet) seen any Human Interface notes on it yet, I would say that floating windows should be hidden ANY time the “parent” window is deactivated, not just when swapped out under MultiFinder (ie. DA to front, unrelated window to front). They should probably be hidden when alerts are brought to the front, but since this situation does not “truly” deactivate the front window, lots of apps don’t take care this case.

Not all applications behave this way, but they probably should.

H.I. notes for Layer Manager (or present ones I haven’t seen, yet) may prove me wrong, but I believe the notes will probably say something similar.

From: Dorothy

Re: Modifying ‘STR ‘s in LSP on Mac

Hi, I’m trying to update my two games Glider+ and Glypha. Problem: Too dumb!

Well, everyone has insisted on a highscores board that saves. I’ve tried both reading in from a ‘STR ‘ resource and then, at the close of the game, modifying it. I’ve tried AddResource after a RemoveResource, etc... Well, with Lightspeed Pascal and 1 meg of memory, I keep damaging my application zone or crashing the whole system. It will claim address errors or low memory errors.

That could well be. I have sampled sounds (although very short ones) and a couple of offscreen ports open during the games. So, I close them, dispose their pointers and still get crashes.

What am I forgetting here? Is there a good way to insure the memory? And how much do I need?

Well, so I tried just creating and opening a file on the disk to save the scores. No. No memory for that operation either. Crash, crash. I’ve bumped the Stack and Zone settings in Lightspeed as high as I dare, but still run out of memory.

From within the program? Specifically ‘STR ‘ resources. How do you correctly define the resource handle so that it’s pointing

Also, what does MoreMasters do? Do I need to call that routine a dozen times?

From: Jhowarth

Re: Modifying ‘STR ‘s in LSP on Mac

I have a STR resource that I change and save in my Reminder INIT. The code is

{1}
var
   myStringHandle:StringHandle
   myNewString:STR255;

begin
...
  myStringHandle := StringHandle(GetResource(‘STR ‘,theID));
  myNewString := myStringHandle^^;
.... Do whatever you need to with the STR255 myNewString ...
  SetString(myStringHandle,myNewString);
  ChangedResource(handle(myStringHandle));
  WriteResource(handle(MyStringHandle));
...
end

You may want to lock the StringHandle when you work on it. ChangedResource marks it for writing out and WriteResource is there for good measure to make the Mac do it immediately and not later. Hope this helps out.

From: Beamer

Re: Moon Phases

Does anyone out there have a formula(e) for calculating the date of the next New Moon, or the current phase of the moon? I program in C, but C or Pascal source, or pseudocode, or even good ol’ algebraic formulas would be greatly appreciated!

From: Venture

Re: Just black screen saver ?

From the stock market opening to the closing bell I would like to blank the screens when there has been no user interaction for a few minutes. Is there a package which just blanks the screens to save them. Packages like Pyro take up

As a last resort I would build the save function into the application, but that is a less than optimal solution.

Your ideas would be appreciated.

From: Jmoreno

Re: Just black screen saver ?

I don’t know of any offhand but blanking the screen is very simple. It takes about six or seven lines of code to do it. Doing it yourself would seem to me to be a better answer than the hassle sure to be involved in bundling someone else’s INIT.

From: Venture

Re: Just black screen saver ?

Thanks, you may be right. My main reason for not wanting to stick it into my own application is that I am running under multifinder and I was anticipating problems with handoffs when running in the background.

I may not have thought enough about it yet and have never written an init so that did not occur to me.

Thanks for the reply.

From: Jmoreno

Re: Just black screen saver ?

A simple way to check to see if you might be interfering with somebody elses app is to make sure that your window is the FrontWindow if it’s not then you can forget about blanking the screen under the theory that the user is working and doesn’t want to see a black screen.

From: Darryl

Re: Where’s the PiMI? (In SuperPaint)

I just finished typing in the ‘Fuzzy Brush’ SuperPaint Plug-In as featured in the Feb. 1990 issue of MacTutor. Every thing that is present in the article looks fine, but what happened to the ‘PiMI’ resource? Looks like I’ll be designing my own About box and icon while a certain editor turns slightly red... I was hoping I could find it here, but I haven’t had any luck. If I can get it here, will someone leave me a message? Either here or (preferably, since this is long distance) on CompuServe (User ID 70157,751). Thanks in advance.

[The PiMI Resource has an ID number of 1600 and only contains $0001 which is the version number. Just create it with ResEdit or another resource editor- ed]

From: Yoda

Re: Tear Off Menus & Palettes

From the routine in the MDEF called DragMenu() where the position is set to the rgnBBox of the dragRgn. Interestingly if the position is set to say (100,100) it works just fine positioning all palettes to (100,100). Somewhere along the way for the Mac IIci the dragRgn’s rgnBBox is getting corrupted. Has anyone else seen this behavior? Anyone know the reason and a solution?

Any help appreciated. Is any one interested in the code for the MPW 3.0 version - particularly if this problem is solved?

From: Madmacs

Re: Multifinder

I need to use a program to start up another program and not to exit itself, sort of the way Multifinder does. I guess the easiest way to explain it is that I want to do a unix like fork() and exec(). I have looked but I can’t find mention of this anywhere and I have never seen a program that needs it. But now I do, does anyone have any suggestions??

From: Pkram

Re: C++ compiler

What really IRRITATES me about Apple’s C++ interpreter, is that it is not a compiler. Why can’t they come up with an AT&T 2.0 true compiler. That they haven’t is truly PATHETIC.

Anyone read the “Nanobytes” section of the Nov ’89 BYTE? AT&T is offering a deal to colleges and universities for students to purchase an AT&T C++ compiler for $25.00. A toll free number 800-828-8649 was also listed in the article.

It is necessary for someone either faculty or administration to purchase the source code for $300.00. After porting the code to the target machine, then students may be licensed to use the binary (not the source) compiler. When I called the 800 number, they said that porting the source should not be very difficult. Now I ask, if a professor at a college or university can produce C++ compilers by porting the source, why can’t Apple do the same? Sure this particular offer is only for educational or non-profit research institutions, but surely Apple could purchase the source for a higher than $300 price.

Surely some decent arrangement between Apple and AT&T could make true C++ compilers for the Mac development community available. Why oh why hasn’t this happened????????

I will NEVER pay more than a few (and I mean $25 or less) for a C++ interpreter. If its not a compiler and if its not TRUE C++ FORGET IT!

From: Siegel

Re: C++ compiler

Actually, Apple C++ is C++ 2.0, with a couple of extensions for greater Mac compatibility. Also, MPW C++ is a preprocessor, not an interpreter. It’s a legitimate, if not ideal, way to implement a C++ compiler.

From: Jhannah

Re: More pixels for your video!

Has anyone ever hacked around and tried to get a Hold-And-Modify effect so that we could have an 8 bit card think it is 16 or 32 bit (or should I say 15 or 24 bit)... is there a small hardware modification to any of the video cards out there that could do this?

By the way, does BIGVIDEO increase the DPI or the # of lines & column of pixels on the monitor?

From: Sysop

Re: More pixels for your video!

BIGVIDEO which is actually called MaxAppleZoom is pretty slick. The DPI is the same at 72 DPI and width and height are increased to use ALL of the screen including the edges that are normally black. Try it if you have a single video card Mac. (It doesn’t work with multiple video cards).

From: Jhannah

Re: More pixels for your video!

Yes but have you ever heard of Hold-And-Modify for the Mac II? (the Amiga sometimes uses this to get more colors).... also, some alternate video cards on the market can squeeze out 768x512 pixels.. thats 64 more horizontal pixels then MaxAppleZoom... is it just a matter of how much video memory is available?

From: Wildman

Re: Tickcount accuracy for stopwatch routine

Another option you consider if you really need better accuracy is to make a little hardware widget to hook to your serial port. A crystal and a driver chip could generate 1Khz square waves. This would give you a character input interrupt 100 times a second. The accuracy could be made comparable to an electronic stopwatch. With a little cleverness and a UART you could even clock in inputs like gun-fired and feet-in- blocks and finish-ribbon-broken. This would get your human reaction time out of the loop, a considerable improvement in timing accuracy. It you are willing to live with keyboard scan randomness, then I suspect that the error drift between Macs is nominal.

 

Community Search:
MacTech Search:

Software Updates via MacUpdate

Latest Forum Discussions

See All

Top Mobile Game Discounts
Every day, we pick out a curated list of the best mobile discounts on the App Store and post them here. This list won't be comprehensive, but it every game on it is recommended. Feel free to check out the coverage we did on them in the links... | Read more »
Price of Glory unleashes its 1.4 Alpha u...
As much as we all probably dislike Maths as a subject, we do have to hand it to geometry for giving us the good old Hexgrid, home of some of the best strategy games. One such example, Price of Glory, has dropped its 1.4 Alpha update, stocked full... | Read more »
The SLC 2025 kicks off this month to cro...
Ever since the Solo Leveling: Arise Championship 2025 was announced, I have been looking forward to it. The promotional clip they released a month or two back showed crowds going absolutely nuts for the previous competitions, so imagine the... | Read more »
Dive into some early Magicpunk fun as Cr...
Excellent news for fans of steampunk and magic; the Precursor Test for Magicpunk MMORPG Crystal of Atlan opens today. This rather fancy way of saying beta test will remain open until March 5th and is available for PC - boo - and Android devices -... | Read more »
Prepare to get your mind melted as Evang...
If you are a fan of sci-fi shooters and incredibly weird, mind-bending anime series, then you are in for a treat, as Goddess of Victory: Nikke is gearing up for its second collaboration with Evangelion. We were also treated to an upcoming... | Read more »
Square Enix gives with one hand and slap...
We have something of a mixed bag coming over from Square Enix HQ today. Two of their mobile games are revelling in life with new events keeping them alive, whilst another has been thrown onto the ever-growing discard pile Square is building. I... | Read more »
Let the world burn as you have some fest...
It is time to leave the world burning once again as you take a much-needed break from that whole “hero” lark and enjoy some celebrations in Genshin Impact. Version 5.4, Moonlight Amidst Dreams, will see you in Inazuma to attend the Mikawa Flower... | Read more »
Full Moon Over the Abyssal Sea lands on...
Aether Gazer has announced its latest major update, and it is one of the loveliest event names I have ever heard. Full Moon Over the Abyssal Sea is an amazing name, and it comes loaded with two side stories, a new S-grade Modifier, and some fancy... | Read more »
Open your own eatery for all the forest...
Very important question; when you read the title Zoo Restaurant, do you also immediately think of running a restaurant in which you cook Zoo animals as the course? I will just assume yes. Anyway, come June 23rd we will all be able to start up our... | Read more »
Crystal of Atlan opens registration for...
Nuverse was prominently featured in the last month for all the wrong reasons with the USA TikTok debacle, but now it is putting all that behind it and preparing for the Crystal of Atlan beta test. Taking place between February 18th and March 5th,... | Read more »

Price Scanner via MacPrices.net

AT&T is offering a 65% discount on the ne...
AT&T is offering the new iPhone 16e for up to 65% off their monthly finance fee with 36-months of service. No trade-in is required. Discount is applied via monthly bill credits over the 36 month... Read more
Use this code to get a free iPhone 13 at Visi...
For a limited time, use code SWEETDEAL to get a free 128GB iPhone 13 Visible, Verizon’s low-cost wireless cell service, Visible. Deal is valid when you purchase the Visible+ annual plan. Free... Read more
M4 Mac minis on sale for $50-$80 off MSRP at...
B&H Photo has M4 Mac minis in stock and on sale right now for $50 to $80 off Apple’s MSRP, each including free 1-2 day shipping to most US addresses: – M4 Mac mini (16GB/256GB): $549, $50 off... Read more
Buy an iPhone 16 at Boost Mobile and get one...
Boost Mobile, an MVNO using AT&T and T-Mobile’s networks, is offering one year of free Unlimited service with the purchase of any iPhone 16. Purchase the iPhone at standard MSRP, and then choose... Read more
Get an iPhone 15 for only $299 at Boost Mobil...
Boost Mobile, an MVNO using AT&T and T-Mobile’s networks, is offering the 128GB iPhone 15 for $299.99 including service with their Unlimited Premium plan (50GB of premium data, $60/month), or $20... Read more
Unreal Mobile is offering $100 off any new iP...
Unreal Mobile, an MVNO using AT&T and T-Mobile’s networks, is offering a $100 discount on any new iPhone with service. This includes new iPhone 16 models as well as iPhone 15, 14, 13, and SE... Read more
Apple drops prices on clearance iPhone 14 mod...
With today’s introduction of the new iPhone 16e, Apple has discontinued the iPhone 14, 14 Pro, and SE. In response, Apple has dropped prices on unlocked, Certified Refurbished, iPhone 14 models to a... Read more
B&H has 16-inch M4 Max MacBook Pros on sa...
B&H Photo is offering a $360-$410 discount on new 16-inch MacBook Pros with M4 Max CPUs right now. B&H offers free 1-2 day shipping to most US addresses: – 16″ M4 Max MacBook Pro (36GB/1TB/... Read more
Amazon is offering a $100 discount on the M4...
Amazon has the M4 Pro Mac mini discounted $100 off MSRP right now. Shipping is free. Their price is the lowest currently available for this popular mini: – Mac mini M4 Pro (24GB/512GB): $1299, $100... Read more
B&H continues to offer $150-$220 discount...
B&H Photo has 14-inch M4 MacBook Pros on sale for $150-$220 off MSRP. B&H offers free 1-2 day shipping to most US addresses: – 14″ M4 MacBook Pro (16GB/512GB): $1449, $150 off MSRP – 14″ M4... Read more

Jobs Board

All contents are Copyright 1984-2011 by Xplain Corporation. All rights reserved. Theme designed by Icreon.