Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Jean

Pages: 1 ... 32 33 [34] 35 36 ... 40
496
Astrobasic / Re: create a temporary file
« on: September 11, 2020, 09:18:12 PM »
if you prefer the memget/memread etc. functions because they are more powerful, i could make a function to search for data in a memory block fast. But i'm not gonna write your script for you, you have to design it yourself, i can only help with the functions. And please do communication about it here on the forum, i will not help via email, i have too much other work and things to do.

497
Astrobasic / Re: create a temporary file
« on: September 11, 2020, 06:55:55 PM »
no it does nothing, sorry, i always use 'i=i' for debugging.

But at that place a duplicate is found and you can see which. What do you want to do with duplicates?

Code: [Select]
window(555, 555);
real planet[PLANETS];
char s[999];

int i, n = readopen("jean.db", 0);
strlist(0, s, 0);
for (i < n)
  {
  readrecord(0, i);
  getplanets(0, planet);
  strset(s, "%d", planet[0]); ` etc
  int m = strlist(12, s, 0);
  if (m = -1)
    strlist(3, s, 0);` not found, add it
  else
    {
    ` here a duplicate is found, it is number m in the stringlist
    }
  }
run;

498
Astrobasic / Multiple Document Interface
« on: September 10, 2020, 07:22:17 PM »
After lots of storm, the dust is settling down. Ab scripts can have embedded windows.

This seems a succes, i like it a lot. Pretty, user friendly, better monitor size support, options for extra menus.
See ab editor - templates - embedded, it contains

Code: [Select]
window(0, 0);
button(10, height - 30, "Menu", NULL);
command(BUTTON, 0, 10, 0);
command(MENU, 0, 12, 0);

The first line is the new window mode.

This is the updated help for window()

----------------------------------------
There are two special kind of windows possible, the first is when you use window(0, 0);

This makes the script window an 'MDI child', Multiple Document Interface, it embeds itself in the main program just like a horoscope (or graph or moving wheel). The Horoscope menu changes to a menu with the name of the script and it will contain all the menu() items from the script.

You can do command(MENU, 0, 12, 0); preferably on the line just before run; it will do two things:
- it will make a copy of the menu in the script mainmenu into a rightmouseclick popmenu, so the user can rightclick anywhere in the window for the script menu (just like the horoscope window).
- it will add a menu item Output, with subitems Copy to clipboard, Save Bitmap and Print to both menus.

You can also put a special ^button^ on the script like this
button(x, y, "Menu", NULL);
command(BUTTON, buttonnumber, 10, 0);

^setcaption^ will only set the upper caption in the mainwindow, if you want it to change the caption in the tab use command(FUNCTION, 67, x, 0); where x is on/off.

You should use 'width' and 'height' when designing your window and try to fit at least on 1920x1080 as well as 1366x768, in this case you can support the majority of screensizes.

499
Planetdance for android / first alpha
« on: September 10, 2020, 04:54:13 PM »
If you want to participate in testing, register on the forum and leave a reply here.

The interface, swipe from the left side to the right for the menu, and from the right side to the left for the current list with horoscopes.
At start a Startup transit is made.

The menu, what works:

-File New, you can calculate a radix, it is automatically stored in the list with horoscopes on the right.
-File Exit
-Horoscope Data, you can scroll up/down through the list of the current horoscope's data.
-Horoscope Wheel gives some test info

In the right hand is a list with horoscopes, click on one to make it active. Long press on one to delete it. The very first entry, Startup, cannot be deleted. The list is automatically saved / restored on start.

500
You can now do this

Code: [Select]
button(0, 0, "hi", NULL);
command(BUTTON, buttonnumber, 0, 0); ` operate on the previously made button

Previously you had to do:

Code: [Select]
int i = button(0, 0, "hi", NULL);
command(BUTTON, i, 0, 0); ` operate on the previously made button

In stead of
Code: [Select]
menu(4, "Show Radix Lines", go);
menu(4, "Show Radix Planets", go);
menu(4, "Show House Lines", go);
command(MENU, 4, AUTOCHECK, 1); 
command(MENU, 5, AUTOCHECK, 1); 
command(MENU, 6, AUTOCHECK, 1);

It's easier to do this

Code: [Select]
menu(4, "Show Radix Lines", go);
command(MENU, menunumber, AUTOCHECK, 1); 
menu(4, "Show Radix Planets", go);
command(MENU, menunumber, AUTOCHECK, 1); 
menu(4, "Show House Lines", go);
command(MENU, menunumber, AUTOCHECK, 1);

In the last example you can now  delete / add / change the order of the menu()'s without having to change the numbers for command().

This applies to: buttonnumber, scrollnumber, editnumber, updownnumber and menunumber;

501
Planetdance for windows / MOVED: strlist command
« on: September 08, 2020, 03:48:17 PM »

502
Astrobasic / Re: create a temporary file
« on: September 07, 2020, 06:28:53 PM »
Yes indeed, try something like this.

Code: [Select]
window(555, 555);
real planet[PLANETS];
char s[999];

int i, n = readopen("jean.db", 0);
strlist(0, s, 0);
for (i < n)
  {
  readrecord(0, i);
  getplanets(0, planet);
  strset(s, "%d", planet[0]); ` etc
  if (strlist(12, s, 0) = -1)
    strlist(3, s, 0);` not found, add it
  else
    {
    ` found
    i=i;
    }
  }
run;

503
Astrobasic / Re: create a temporary file
« on: September 07, 2020, 05:03:27 PM »
Sorry, i see this only now.
You code is very confusing to me, please describe what you want.
I see a memval() but i don't see how you filled that memory.

If you want to search for a string in memory, this is an example using strlist().
You need to update for this!

Code: [Select]
window(555, 555);
char s[99];

strlist(0, s, 0); ` create the list
int n, i = 0; for (i < 16)
  strlist(3, planetname[i], i); ` add planetnames

strcpy(s, "blabla");
n = strlist(12, s, 0);           ` is it in the list?
if (n > 0)
  say(s, "found");
else
  say(s, "not found");

strcpy(s, "Mars");
n = strlist(12, s, 0);
if (n > 0)
  say(s, "found");
else
  say(s, "not found");
run;

I moved the other message, please keep things in one place, thank you.

504
Ik weet zelf niet direct iets maar ik zal eens navragen.

505
General Astrology Topics / Re: welcome to the boards
« on: September 07, 2020, 04:29:15 PM »
Hoi Ima,

Welkom op het forum. Je kan rustig nederlands gebruiken hoor.

507
Planetdance for windows / Re: embedded script windows.
« on: September 06, 2020, 01:57:33 PM »
So far i've only seen people being enthousiast about it.
I say maybe try it a few days if something funny comes up, then make this a new standard.
I'd even postpone the android work a few days to convert some more scripts.
Note not all scripts are evenly suited.
Others could have interesting possibilities yes, like time list with space on the left for graphs or something.
Dazzling. :)

508
Planetdance for windows / embedded script windows.
« on: September 06, 2020, 12:17:14 PM »
When i designed it, I choose to make the astrobasic window form a separate one, and give it an entry in the taskbar because else you couldn't make a small simple scripts to show some info.
But more extensive scripts could benefit from being embedded like horoscopes.

Pro / cons.

+ the most screenspace
+ user friendly, a tab like the others
+ has been requested
- the programmer has more work (use vars width / height to determine how much, what / where to display).
- There is no main menu at the top possible (but there is a button which has the same functionality).

The screenshot is

509
Classic, Medieval, Vedic / Re: Medieval Traditional Chart
« on: September 05, 2020, 01:23:08 PM »
Well it's turning out rather complicated. It's a little bit better now but not optimal. I'm gonna try something new for WHS but that will take a bit of time.

[Edit] 1 hour later, i tried a few things but the part that draws a horoscope is quite complex and i'd have to redesign things to improve this situation. Frankly i'm not too happy with this but for now it's the best i can do. You can see the problem illustrated when you move a horoscope in time per minute using the arrows. The housecusps dance a bit round the signcusps, sometimes exact, sometimes one pixel off.
[Edit 2] If you still see cusps that are off too much, please redownload.

510
Planetdance for windows / Re: shortcuts
« on: September 04, 2020, 07:52:31 PM »
ah that's what you mean, see pic.

for the second question, yes, those modules are separate windows and don't react to the window menu.

Pages: 1 ... 32 33 [34] 35 36 ... 40