<commit_before><?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
<?xml-stylesheet href="chrome://automatic_dictionary/content/preferences.css" type="text/css"?>
<!DOCTYPE window SYSTEM "chrome://automatic_dictionary/locale/preferences.dtd">
<prefwindow id="automatic_dictionary-prefs"
     title="AutomaticDictionary Preferences"
     xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
     onload="var descriptions = document.getElementsByTagName('description'); for (var i=0; i&lt;descriptions.length; i++) { descriptions[i].style.height=document.defaultView.getComputedStyle(descriptions[i], null).getPropertyValue('height');}"
    >
    <!-- onload to fix prefpanel size https://bugzilla.mozilla.org/show_bug.cgi?id=451997 -->
    <script language="JavaScript" src="chrome://automatic_dictionary/content/ad.js"/>
    <script language="JavaScript">
        //Bootup and shutdown to migrate data when required.
        var ad = new AutomaticDictionary.Class({
                        window: window,
                        compose_window_builder: AutomaticDictionary.ComposeWindowStub
                    });
        ad.stop();

function sendLogToDeveloper(link){
    try{
        var body = document.getElementById('mailToDev_body').textContent;
        var subject = document.getElementById('mailToDev_subject').textContent;
        AutomaticDictionary.Lib.MailComposer.openComposeMailWindow(
            '<EMAIL>',null, subject, body,
            [AutomaticDictionary.logger.filepath]);
    }catch(e){ AutomaticDictionary.logger.error(e)}
}
    </script>
    <script language="JavaScript" src="chrome://automatic_dictionary/content/preferences.js"/>

    <prefpane id="main-pane" label="Preferencess" style="overflow:auto;">
        <preferences>
            <preference id="maxSize" name="extensions.automatic_dictionary.addressesInfo.maxSize" type="int"/>
            <preference id="maxRecipients" name="extensions.automatic_dictionary.maxRecipients" type="int"/>
            <preference id="allowCollect" name="extensions.automatic_dictionary.allowCollect" type="bool"/>
            <preference id="allowPromotions" name="extensions.automatic_dictionary.allowPromotions" type="bool"/>
            <preference id="notificationLevel" name="extensions.automatic_dictionary.notificationLevel" type="string"/>
            <preference id="logLevel" name="extensions.automatic_dictionary.logLevel" type="string"/>
            <preference id="saveLogFile" name="extensions.automatic_dictionary.saveLogFile" type="bool"/>
        </preferences>
        <!-- little hack: hidden tags to have translated mailToDev strings -->
        <description class="hidden_js_string" id="mailToDev_subject"
                     >&mailToDev.subject;</description>
        <description class="hidden_js_string" id="mailToDev_body"
                     >&mailToDev.body;</description>

        <vbox class="prefoptions">
            <hbox>
                <label control="input_allowCollect" value="&allowCollect.label;"/>
                <checkbox preference="allowCollect" id="input_allowCollect" />
                <label value="" flex="10"/>
            </hbox>
            <description class="info">
                &allowCollect.info;
                &allowCollect.recomendation;
            </description>
            <!-- Remember to set the promotion id upper in this file at <preferences> -->
            <hbox>
                <label control="input_allowPromotions" value="&allowPromotions.label;"/>
                <checkbox preference="allowPromotions" id="input_allowPromotions" />
                <label value="" flex="10"/>
            </hbox>
            <description class="info">
                &allowPromotions.info;
                &allowPromotions.recomendation;
            </description>
            
            <hbox>
                <label control="input_notificationLevel" value="&notificationLevel.label;"/>
                <!-- List example (this example would be stored as an integer) -->
                <setting pref="extensions.automatic_dictionary.notificationLevel" type="menulist" title="">
                  <menulist preference="notificationLevel">
                    <menupopup>
                      <menuitem value="info" label="&notificationLevel.info;"/>
                      <menuitem value="warn" label="&notificationLevel.warn;"/>
                      <menuitem value="error" label="&notificationLevel.error;"/>
                    </menupopup>
                  </menulist>
                </setting>
                <label value="" flex="10"/>
            </hbox>
            <description class="info">
                &notificationLevel.description;
                &notificationLevel.recommendation;
            </description><commit_msg>Fix preferences window height on Windows<commit_after><?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
<?xml-stylesheet href="chrome://automatic_dictionary/content/preferences.css" type="text/css"?>
<!DOCTYPE window SYSTEM "chrome://automatic_dictionary/locale/preferences.dtd">
<prefwindow id="automatic_dictionary-prefs"
     title="AutomaticDictionary Preferences"
     xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
    >
    <!-- onload to fix prefpanel size https://bugzilla.mozilla.org/show_bug.cgi?id=451997 -->
    <script language="JavaScript" src="chrome://automatic_dictionary/content/ad.js"/>
    <script language="JavaScript">

    window.addEventListener("DOMContentLoaded", function(evt){
          document.documentElement.style.maxWidth = ((screen.availWidth || screen.width) - 100) + "px";
          document.documentElement.style.maxHeight = ((screen.availHeight || screen.height) - 100) + "px";

          var descriptions = document.getElementsByTagName('description');
          for (var i=0; i &lt; descriptions.length; i++) {
              descriptions[i].style.height=document.defaultView.getComputedStyle(descriptions[i], null).getPropertyValue('height');
          }
    });

        //Bootup and shutdown to migrate data when required.
        var ad = new AutomaticDictionary.Class({
                        window: window,
                        compose_window_builder: AutomaticDictionary.ComposeWindowStub
                    });
        ad.stop();

function sendLogToDeveloper(link){
    try{
        var body = document.getElementById('mailToDev_body').textContent;
        var subject = document.getElementById('mailToDev_subject').textContent;
        AutomaticDictionary.Lib.MailComposer.openComposeMailWindow(
            '<EMAIL>',null, subject, body,
            [AutomaticDictionary.logger.filepath]);
    }catch(e){ AutomaticDictionary.logger.error(e)}
}
    </script>
    <script language="JavaScript" src="chrome://automatic_dictionary/content/preferences.js"/>

    <prefpane id="main-pane" label="Preferencess" style="overflow:auto;">
        <preferences>
            <preference id="maxSize" name="extensions.automatic_dictionary.addressesInfo.maxSize" type="int"/>
            <preference id="maxRecipients" name="extensions.automatic_dictionary.maxRecipients" type="int"/>
            <preference id="allowCollect" name="extensions.automatic_dictionary.allowCollect" type="bool"/>
            <preference id="allowPromotions" name="extensions.automatic_dictionary.allowPromotions" type="bool"/>
            <preference id="notificationLevel" name="extensions.automatic_dictionary.notificationLevel" type="string"/>
            <preference id="logLevel" name="extensions.automatic_dictionary.logLevel" type="string"/>
            <preference id="saveLogFile" name="extensions.automatic_dictionary.saveLogFile" type="bool"/>
        </preferences>
        <!-- little hack: hidden tags to have translated mailToDev strings -->
        <description class="hidden_js_string" id="mailToDev_subject"
                     >&mailToDev.subject;</description>
        <description class="hidden_js_string" id="mailToDev_body"
                     >&mailToDev.body;</description>

        <vbox class="prefoptions">
            <hbox>
                <label control="input_allowCollect" value="&allowCollect.label;"/>
                <checkbox preference="allowCollect" id="input_allowCollect" />
                <label value="" flex="10"/>
            </hbox>
            <description class="info">
                &allowCollect.info;
                &allowCollect.recomendation;
            </description>
            <!-- Remember to set the promotion id upper in this file at <preferences> -->
            <hbox>
                <label control="input_allowPromotions" value="&allowPromotions.label;"/>
                <checkbox preference="allowPromotions" id="input_allowPromotions" />
                <label value="" flex="10"/>
            </hbox>
            <description class="info">
                &allowPromotions.info;
                &allowPromotions.recomendation;
            </description>

            <hbox>
                <label control="input_notificationLevel" value="&notificationLevel.label;"/>
                <!-- List example (this example would be stored as an integer) -->
                <setting pref="extensions.automatic_dictionary.notificationLevel" type="menulist" title="">
                  <menulist preference="notificationLevel">
                    <menupopup>
                      <menuitem value="info" label="&notificationLevel.info;"/>
                      <menuitem value="warn" label="&notificationLevel.warn;"/>
                      <menuitem value="error" label="&notificationLevel.error;"/>
                    </menupopup>
                  </menulist>
                </setting>
                <label value="" flex="10"/>
            </hbox>
            <description class="info">
                &notificationLevel.description;
                &notificationLevel.recommendation;
            </description>
{'fraction_non_alphanumeric': 0.12823847154146245, 'fraction_numerical': 0.003601080324097229, 'mean_word_length': 2.6132996024575355, 'pattern_counts': {'":': 0, '<': 121, '<?xml version=': 2, '>': 121, 'https://': 2, 'lorem ipsum': 0, 'www.': 2, 'xml': 8}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3492156', 'n_tokens_mistral': 2642, 'n_tokens_neox': 2449, 'n_words': 446}