<?xml version="1.0" encoding="UTF-8"?>

<?context-directive job ctxfile x-setups.ctx ?>

<cd:interface xmlns:cd="http://www.pragma-ade.com/commands">

    <cd:command name="defineinsertion" level="system" category="structure" file="page-ins.mkxl">
        <cd:arguments>
            <cd:resolve name="keyword-name"/>
            <cd:resolve name="keyword-name-optional"/>
            <cd:assignments list="yes" optional="yes">
                <cd:inherit name="setupinsertion"/>
            </cd:assignments>
        </cd:arguments>
    </cd:command>

    <cd:command name="setupinsertion" level="system" category="structure" file="page-ins.mkxl">
        <cd:arguments>
            <cd:resolve name="keyword-name-list-optional"/>
            <cd:assignments list="yes">
                <cd:parameter name="location">
                    <cd:constant type="page" default="yes"/>
                    <cd:constant type="text"/>
                    <cd:constant type="columns"/>
                    <cd:constant type="firstcolumn"/>
                    <cd:constant type="lastcolumn"/>
                </cd:parameter>
                <cd:parameter name="anchoring">
                    <cd:constant type="auto" default="yes"/>
                </cd:parameter>
            </cd:assignments>
        </cd:arguments>
    </cd:command>

    <cd:command name="setcurrentinsertion" level="system" category="structure" file="page-ins.mkxl">
        <cd:arguments>
            <cd:resolve name="argument-name"/>
        </cd:arguments>
    </cd:command>

    <cd:command name="processinsertions" level="system" category="structure" file="page-ins.mkxl"/>

    <cd:command name="doifelseinsertion" level="system" category="structure" keywords="conditional" file="page-ins.mkxl">
        <cd:arguments>
            <cd:resolve name="argument-name"/>
            <cd:resolve name="argument-true"/>
            <cd:resolve name="argument-false"/>
        </cd:arguments>
    </cd:command>

    <cd:command name="doifinsertionelse" level="system" category="structure" keywords="conditional" file="page-ins.mkxl">
        <cd:arguments>
            <cd:resolve name="argument-name"/>
            <cd:resolve name="argument-true"/>
            <cd:resolve name="argument-false"/>
        </cd:arguments>
    </cd:command>

    <cd:command name="detachinsertions" level="system" category="structure" file="page-ins.lmt">
        <cd:arguments>
            <cd:resolve name="string-number"/>
        </cd:arguments>
    </cd:command>

    <cd:command name="attachinsertions" level="system" category="structure" file="page-ins.lmt">
        <cd:arguments>
            <cd:csname/>
        </cd:arguments>
    </cd:command>

    <cd:command name="attachinsertion" level="system" category="structure" file="page-ins.lmt">
        <cd:arguments>
            <cd:resolve name="string-number"/>
            <cd:csname/>
        </cd:arguments>
    </cd:command>

    <cd:command name="nofdetachedinsertions" level="system" category="structure" file="page-ins.lmt">
        <cd:arguments>
            <cd:resolve name="string-number"/>
        </cd:arguments>
    </cd:command>

    <cd:command name="attachinsert" level="system" category="structure" file="page-ins.mkxl">
        <cd:arguments>
            <cd:content/>
        </cd:arguments>
    </cd:command>

</cd:interface>
