Better check for 64-bit.
[AROS-Contrib.git] / scout / source / scout_defs.h
blob66556acd6a2f7da7768bac735e52231d60753ef2
1 /**
2 * Scout - The Amiga System Monitor
4 *------------------------------------------------------------------
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 *------------------------------------------------------------------
22 * @author Andreas Gelhausen
23 * @author Richard Körber <rkoerber@gmx.de>
24 * @author Pavel Fedin <sonic_amiga@mail.ru>
27 #ifndef SCOUT_DEFS_H
28 #define SCOUT_DEFS_H
30 /*************************************************************/
31 /* User definitions */
32 /*************************************************************/
34 #define FILENAME_LENGTH 512
35 #define VERSION_LENGTH 16
36 #if (__WORDSIZE == 64)
37 #define ADDRESS_LENGTH 32
38 #define ADDRESS_FORMAT "$%016lx"
39 #else
40 #define ADDRESS_LENGTH 16
41 #define ADDRESS_FORMAT "$%08lx"
42 #endif
43 #define PATH_LENGTH 512
44 #define PATH_LENGTH_CHAR "512"
45 #define NODENAME_LENGTH 512
46 #define TEXT_LENGTH 512
47 #define TEXT_LENGTH_CHAR "512"
48 #define NODETYPE_LENGTH 16
49 #define NUMBER_LENGTH 16
50 #define TASK_STATE_LENGTH 16
51 #define TMP_STRING_LENGTH 1024
52 #define TS_FROZEN 0xff
53 #define PATTERN_LENGTH (PATH_LENGTH * 2 + 2)
54 #define NODESUBSYS_LENGTH 32
55 #define NODESUBTYPE_LENGTH 32
57 static inline struct List *ListPtr(APTR list)
59 return (struct List *)list;
62 #define ITERATE_LIST(list, type, node) for (node = (type)ListPtr(list)->lh_Head; ((struct Node *)node)->ln_Succ; node = (type)((struct Node *)node)->ln_Succ)
63 #define ITERATE_LIST_REVERSE(list, type, node) for (node = (type)ListPtr(list)->lh_TailPred; ((struct Node *)node)->ln_Pred; node = (type)((struct Node *)node)->ln_Pred)
65 #define MakeID(a,b,c,d) ((ULONG) (a)<<24 | (ULONG) (b)<<16 | (ULONG) (c)<<8 | (ULONG) (d))
67 #define MyTextFrame TextFrame,MUIA_Background,MUII_TextBack
69 #define LabelA(label) TextObject,MUIA_Text_PreParse,(IPTR)"\033r",\
70 MUIA_Text_Contents,(IPTR)label,TextFrame,MUIA_FramePhantomHoriz,\
71 TRUE,End
73 #define LabelB(label) TextObject,MUIA_Text_PreParse,(IPTR)"\033r",\
74 MUIA_Text_Contents,(IPTR)label,TextFrame,MUIA_FramePhantomHoriz,\
75 TRUE,MUIA_Weight,0,MUIA_InnerLeft,0,MUIA_InnerRight,0,End
77 #define LabelC(label) TextObject,MUIA_Text_PreParse,(IPTR)"\033c",\
78 MUIA_Text_Contents,(IPTR)label,TextFrame,MUIA_FramePhantomHoriz,\
79 TRUE,End
81 #ifndef ZERO
82 #define ZERO ((BPTR)0L)
83 #endif
85 #endif /* SCOUT_DEFS_H */