+/* sort priorities of artwork */
+#define ARTWORKCLASS_CLASSICS_START 100
+#define ARTWORKCLASS_CLASSICS_END 199
+#define ARTWORKCLASS_CONTRIBUTION_START 200
+#define ARTWORKCLASS_CONTRIBUTION_END 299
+#define ARTWORKCLASS_LEVEL_START 300
+#define ARTWORKCLASS_LEVEL_END 399
+#define ARTWORKCLASS_USER_START 400
+#define ARTWORKCLASS_USER_END 499
+
+#define ARTWORKCLASS_CLASSICS ARTWORKCLASS_CLASSICS_START
+#define ARTWORKCLASS_CONTRIBUTION ARTWORKCLASS_CONTRIBUTION_START
+#define ARTWORKCLASS_LEVEL ARTWORKCLASS_LEVEL_START
+#define ARTWORKCLASS_USER ARTWORKCLASS_USER_START
+
+#define ARTWORKCLASS_UNDEFINED 999
+
+#define IS_ARTWORKCLASS_CLASSICS(p) \
+ ((p)->sort_priority >= ARTWORKCLASS_CLASSICS_START && \
+ (p)->sort_priority <= ARTWORKCLASS_CLASSICS_END)
+#define IS_ARTWORKCLASS_CONTRIBUTION(p) \
+ ((p)->sort_priority >= ARTWORKCLASS_CONTRIBUTION_START && \
+ (p)->sort_priority <= ARTWORKCLASS_CONTRIBUTION_END)
+#define IS_ARTWORKCLASS_LEVEL(p) \
+ ((p)->sort_priority >= ARTWORKCLASS_LEVEL_START && \
+ (p)->sort_priority <= ARTWORKCLASS_LEVEL_END)
+#define IS_ARTWORKCLASS_USER(p) \
+ ((p)->sort_priority >= ARTWORKCLASS_USER_START && \
+ (p)->sort_priority <= ARTWORKCLASS_USER_END)
+
+#define ARTWORKCLASS(n) (IS_ARTWORKCLASS_CLASSICS(n) ? ARTWORKCLASS_CLASSICS :\
+ IS_ARTWORKCLASS_CONTRIBUTION(n) ? ARTWORKCLASS_CONTRIBUTION : \
+ IS_ARTWORKCLASS_LEVEL(n) ? ARTWORKCLASS_LEVEL : \
+ IS_ARTWORKCLASS_USER(n) ? ARTWORKCLASS_USER : \
+ ARTWORKCLASS_UNDEFINED)
+
+
+void setLevelArtworkDir(TreeInfo *);