Re: newbie question, wrapping text
Hi Jose, Ok, many thanks. Sadhu | Hi Sadhu, | | I understand you want to pad the text to a fixed lenght (in fld 1 or in a | variable) to a fld 2. Try this: | | local thetext, counterr, tam | on mouseup | put 0 into counterr | put 80 into tam | | repeat for each char x in fld 1 | add 1 to counterr | if x=cr then ---you have to control if the char is a return | put cr after thetext | put 0 into counterr | else | put x after thetext | end if | | if counterr=tam then | put 0 into counterr | put cr after thetext | end if | end repeat | | put thetext into fld 2 | end mouseup | | Sure the script may be tunned, but even in this form it is very fast for | small texts (some thousands of chars). | | Regards, | | Jose L. Rodriguez ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: newbie question (text wrap)
> > A newbie question: > > I want to wrap some single line text in a text box and not use a > horizontal scroll bar. I have an algorithm that works. > > But it is horribly inefficient and I'm sure there must be a better way! > Can you X-talk gurus help me out with this one? > > if (the length of this_line > 80) then > repeat with i = 1 to the length of this_line > put char i of this_line after field "contents" > if (i mod 80 = 0) then put return after field "contents" > end repeat > end if > > Mahalo! Hi Sadhu, I understand you want to pad the text to a fixed lenght (in fld 1 or in a variable) to a fld 2. Try this: local thetext, counterr, tam on mouseup put 0 into counterr put 80 into tam repeat for each char x in fld 1 add 1 to counterr if x=cr then ---you have to control if the char is a return put cr after thetext put 0 into counterr else put x after thetext end if if counterr=tam then put 0 into counterr put cr after thetext end if end repeat put thetext into fld 2 end mouseup Sure the script may be tunned, but even in this form it is very fast for small texts (some thousands of chars). Regards, Jose L. Rodriguez ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: newbie question
In a message dated 28/01/2003 01:39:34 AM GMT Standard Time, [EMAIL PROTECTED] writes: A newbie question: I want to wrap some single line text in a text box and not use a horizontal scroll bar. I have an algorithm that works. But it is horribly inefficient and I'm sure there must be a better way! Can you X-talk gurus help me out with this one? if (the length of this_line > 80) then repeat with i = 1 to the length of this_line put char i of this_line after field "contents" if (i mod 80 = 0) then put return after field "contents" end repeat end if Mahalo! Just set the dontWrap of the field to "true". /H _ Hugh Senior The Flexible Learning Company Consultant Programming & Software Solutions Fax/Voice: +44 (0)1483.27 87 27 Email: mailto:[EMAIL PROTECTED] Web: www.flexibleLearning.com
newbie question
Yo, A newbie question: I want to wrap some single line text in a text box and not use a horizontal scroll bar. I have an algorithm that works. But it is horribly inefficient and I'm sure there must be a better way! Can you X-talk gurus help me out with this one? if (the length of this_line > 80) then repeat with i = 1 to the length of this_line put char i of this_line after field "contents" if (i mod 80 = 0) then put return after field "contents" end repeat end if Mahalo! ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Newbie question about the bucket tool
On Sun, 29 Dec 2002 [EMAIL PROTECTED] wrote: > Bonjour, > > I don’t understand why the paint tools which work with macOS behave in a > strange way with Windows. > > If I choose a color (for instance a green defined by the RGB values > 125,255,O), I expect each pixel which I paint to have exactly this color. > This is performed without any problem by my mac. > My computer running with Windows OS seems to display the chosen color, > but in facts, the area which is should painted with it is filled with a > mosaic of pixels with slightly different colors. (If the chosen color is > 125,255,O, then the colors of the mosaic are 115,255,0 and 123,255,0). > When a shape is filled with a mosaic instead of a plain color, of course > the bucket tool will operate only on the contiguous pixels having exactly the > same color. > Could anyone help me with mastering the paint tools or explain me why > Windows does not allow me to paint with the exact colors I choose ? The only thing I can guess is that you're running in 8-bit (256-color) mode and your graphics card is being too clever and dithering even when it's not supposed. Running in 32-bit depth is the best solution to this problem, but I'd also consider that graphics card and/or driver to be suspect and one or both probably should be upgraded. Regards, Scott > Thank you for your help > Cordialement, > Jean-Paul Poccard Scott Raney [EMAIL PROTECTED] http://www.metacard.com MetaCard: You know, there's an easier way to do that... ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Newbie question about the bucket tool.
Bonjour, I don’t understand why the paint tools which work with macOS behave in a strange way with Windows. If I choose a color (for instance a green defined by the RGB values 125,255,O), I expect each pixel which I paint to have exactly this color. This is performed without any problem by my mac. My computer running with Windows OS seems to display the chosen color, but in facts, the area which is should painted with it is filled with a mosaic of pixels with slightly different colors. (If the chosen color is 125,255,O, then the colors of the mosaic are 115,255,0 and 123,255,0). When a shape is filled with a mosaic instead of a plain color, of course the bucket tool will operate only on the contiguous pixels having exactly the same color. Could anyone help me with mastering the paint tools or explain me why Windows does not allow me to paint with the exact colors I choose ? Thank you for your help Cordialement, Jean-Paul Poccard ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: Newbie with a newbie question
[EMAIL PROTECTED] wrote: > > When I > click to put an icon on a button, the icon doesn't get placed. I have to > create a new stack and put a button with an icon on it to get the number so I > can enter the number on my original stack to get he icon to show up. This > just started happening yesterday after a few weeks of working on the stack > with no problems. When you say you click to place an icon, do you mean you are using MetaCard's icon chooser? I wonder if you have other images in your stack with the same ID number. That might cause a problem. -- Jacqueline Landman Gay | [EMAIL PROTECTED] HyperActive Software | 612-724-1596 Custom hypermedia solutions| http://www.hyperactivesw.com Archives: http://www.mail-archive.com/metacard@lists.runrev.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to <[EMAIL PROTECTED]>, not this list.
Newbie with a newbie question
Hello all, Just began working with MC after years as a HyperCard guy. Things have been going okay but have run into a problem with a stack I'm working on. When I click to put an icon on a button, the icon doesn't get placed. I have to create a new stack and put a button with an icon on it to get the number so I can enter the number on my original stack to get he icon to show up. This just started happening yesterday after a few weeks of working on the stack with no problems. Any ideas? I've already rerun MC so it's not the program. Could I have unknowingly done something to the stack to cause this? Allen CarterAC Muzik P. O. Box 1239 [EMAIL PROTECTED] Romoland, CA 92585 http://www.acmuzik.com 909-926-8545909-926-9545 (fax) Archives: http://www.mail-archive.com/metacard@lists.runrev.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to <[EMAIL PROTECTED]>, not this list.