/* NOTES.RSS */

#include <hwim.rh>
#include <hwim.rg>
#include <notes.rg>
#include <s_.h>

RESOURCE WSERV_INFO notes_accs
    {
    menbar_id=notes_menubar;
    first_com=O_COM_EXIT;
    accel={'x',
           'a','j','k','d','r','u',
           'i','c','b','e','z',
           't','n','f',
           'o','s','w','q','l',
           '+','-','*','/',
           'g','m','h','y','p'};
    }

RESOURCE MENU_BAR notes_menubar
    {
    items =
        {
        MENU_BAR_ITEM
            {
            menu_id=notes_menu;
            mb_item="Notes";
            },
        MENU_BAR_ITEM
            {
            menu_id=edit_menu;
            mb_item="Edit";
            },
        MENU_BAR_ITEM
            {
            menu_id=windows_menu;
            mb_item="Windows";
            },
        MENU_BAR_ITEM
            {
            menu_id=search_menu;
            mb_item="Search";
            },
        MENU_BAR_ITEM
            {
            menu_id=tag_menu;
            mb_item="Tag";
            },
        MENU_BAR_ITEM
            {
            menu_id=special_menu;
            mb_item="Special";
            }
        };
    }

RESOURCE MENU notes_menu
    {
    items =
        {
        MENU_ITEM
            {
            com_id=O_NCON_NEW;
            mn_item="New note";
            },
        MENU_ITEM
            {
            com_id=O_NCON_INSERT;
            mn_item="Insert note";
            },
        MENU_ITEM
            {
            com_id=O_NCON_COPY;
            mn_item="Copy note";
            },
        MENU_ITEM
            {
            com_id=O_NCON_DELETE;
            mn_item="Delete note";
            },
        MENU_ITEM
            {
            com_id=O_NCON_RECORD;
            mn_item="Record";
            },
        MENU_ITEM
            {
            com_id=O_NCON_UNDO;
            mn_item="Undo";
            }
        };
    }

RESOURCE MENU edit_menu
    {
    items =
        {
        MENU_ITEM
            {
            com_id=O_NCOE_INSERT;
            mn_item="Insert text";
            },
        MENU_ITEM
            {
            com_id=O_NCOE_COPY;
            mn_item="Copy text";
            },
        MENU_ITEM
            {
            com_id=O_NCOE_BRING;
            mn_item="Bring";
            },
        MENU_ITEM
            {
            com_id=O_NCOE_EVALUATE;
            mn_item="Evaluate";
            },
        MENU_ITEM
            {
            com_id=O_NCOE_SUM;
            mn_item="Sum";
            }
        };
    }

RESOURCE MENU windows_menu
    {
    items =
        {
        MENU_ITEM
            {
            com_id=O_NCOW_TITLE;
            mn_item="Title window";
            },
        MENU_ITEM
            {
            com_id=O_NCOW_NOTES;
            mn_item="Notes window";
            },
        MENU_ITEM
            {
            com_id=O_NCOW_FIND;
            mn_item="Find window";
            }
        };
    }

RESOURCE MENU search_menu
    {
    items =
        {
        MENU_ITEM
            {
            com_id=O_NCOS_OPTIONS;
            mn_item="Options";
            },
        MENU_ITEM
            {
            com_id=O_NCOS_FORWARDS;
            mn_item="Search forwards";
            },
        MENU_ITEM
            {
            com_id=O_NCOS_BACKWARDS;
            mn_item="Search backwards";
            },
        MENU_ITEM
            {
            com_id=O_NCOS_FIRST;
            mn_item="Search first";
            },
        MENU_ITEM
            {
            com_id=O_NCOS_LAST;
            mn_item="Search last";
            }
        };
    }

RESOURCE MENU tag_menu
    {
    items =
        {
        MENU_ITEM
            {
            com_id=O_NCOT_SET;
            mn_item="Set";
            },
        MENU_ITEM
            {
            com_id=O_NCOT_CLEAR;
            mn_item="Clear";
            },
        MENU_ITEM
            {
            com_id=O_NCOT_SET_ALL;
            mn_item="Tag all";
            },
        MENU_ITEM
            {
            com_id=O_NCOT_CLEAR_ALL;
            mn_item="Clear all";
            }
        };
    }

RESOURCE MENU special_menu
    {
    items =
        {
        MENU_ITEM
            {
            com_id=O_NCOX_GOTO;
            mn_item="Go to";
            },
        MENU_ITEM
            {
            com_id=O_NCOX_MOVETO;
            mn_item="Move to";
            },
        MENU_ITEM
            {
            com_id=O_NCOX_SYMBOLS;
            mn_item="Show symbols";
            },
        MENU_ITEM
            {
            com_id=O_NCOX_PSETUP;
            mn_item="Print setup";
            },
        MENU_ITEM
            {
            com_id=O_NCOX_PRINT;
            mn_item="Print";
            },
        MENU_ITEM
            {
            com_id=O_COM_EXIT;
            mn_item="Exit";
            }
        };
    }

RESOURCE STRING nostr_find_prompt { str="Find: "; }     /* includes space */
RESOURCE STRING nostr_max_number_notes { str="Maximum number of notes already reached"; }

RESOURCE STRING nostr_no_note_inserted { str="No note to insert"; }
RESOURCE STRING nostr_note_copied { str="Note copied"; }
RESOURCE STRING nostr_no_note_copied { str="No note to copy"; }
RESOURCE STRING nostr_note_recorded { str="Note recorded"; }

RESOURCE STRING nostr_no_text_inserted { str="No text to insert"; }
RESOURCE STRING nostr_no_text_copied { str="No text to copy"; }
RESOURCE STRING nostr_text_copied { str="Text copied"; }
RESOURCE STRING nostr_only_in_notes { str="Only available in notes window"; }
RESOURCE STRING nostr_tag_count { str="Number of notes currently tagged: %d"; }
RESOURCE STRING nostr_delete_note { str="Delete this note"; }
RESOURCE STRING nostr_undo_editing { str="Undo editing"; }
RESOURCE STRING nostr_not_found { str="Not found"; }
RESOURCE STRING nostr_not_changed { str="Not changed"; }

RESOURCE DIALOG nodl_goto
    {
    flags=DLGBOX_NOTIFY_ENTER|DLGBOX_RBUF_FILLED;
    title="Go to";
    controls=
    	{
    	CONTROL
    	    {
    	    class=C_NCEDIT;
    	    prompt="Note number";
    	    info=NCEDIT
    		{
    		low=1;
    		high=99;
    		};
    	    }
    	};
    }

RESOURCE DIALOG nodl_moveto
    {
    flags=DLGBOX_NOTIFY_ENTER|DLGBOX_RBUF_FILLED;
    title="Move note";
    controls=
    	{
    	CONTROL
    	    {
    	    class=C_NCEDIT;
    	    prompt="New note number";
    	    info=NCEDIT
    		{
    		low=1;
    		high=99;
    		};
    	    }
    	};
    }

RESOURCE MENU nom_find_types
    {
    items =
        {
        CHOICE_ITEM { str="Just notes";},
        CHOICE_ITEM { str="Just title";},
        CHOICE_ITEM { str="Title and notes";}
        };
    }

RESOURCE DIALOG nodl_options
    {
    title="Options for search";
    flags=DLGBOX_NOTIFY_ENTER;
    controls=
        {
        CONTROL
            {
            class=C_CHLIST;
            prompt="Case sensitive";
            info=CHLIST { rid=-SYS_NO_YES; };
            },
        CONTROL
            {
            class=C_CHLIST;
            prompt="Search";
            info=CHLIST { rid=nom_find_types; };
            }
        };
    }
