<commit_before>package org.runestar.client.api

import com.alee.managers.style.StyleId
import com.alee.managers.tooltip.TooltipManager
import com.alee.managers.tooltip.WebCustomTooltip
import org.kxtra.slf4j.logger.info
import org.kxtra.slf4j.loggerfactory.getLogger
import org.kxtra.swing.component.windowAncestor
import java.awt.*
import java.util.*
import javax.swing.*

class SidePanel internal constructor() : JPanel(BorderLayout()) {

    companion object {
        const val PANEL_WIDTH = 225
        const val BAR_WIDTH = 24
        const val WIDTH = PANEL_WIDTH + BAR_WIDTH
    }

    private val tabs: SortedSet<TabButton> = TreeSet()

    private val buttons: SortedSet<BarButton> = TreeSet()

    internal val panel: JPanel

    private val buttonsBox: Box

    private val logger = getLogger()

    private var selectedTab: TabButton? = null

    init {
        panel = JPanel(BorderLayout()).apply {
            preferredSize = Dimension(PANEL_WIDTH, 0)
            minimumSize = preferredSize
            maximumSize = Dimension(PANEL_WIDTH, Int.MAX_VALUE)
            isVisible = false
        }
        buttonsBox = Box.createVerticalBox().apply {
            preferredSize = Dimension(BAR_WIDTH, 0)
            minimumSize = preferredSize
            maximumSize = Dimension(BAR_WIDTH, Int.MAX_VALUE)
        }
        add(
                Box.createHorizontalBox().apply {
                    add(panel)
                    add(buttonsBox)
                }
        )
    }

    fun add(tab: TabButton) {
        if (!tabs.add(tab)) {
            logger.info { "Cannot add $tab, it is already present" }
            return
        }
        rebuild()
    }
<commit_msg>Reverse side panel horizontal order<commit_after>package org.runestar.client.api

import com.alee.managers.style.StyleId
import com.alee.managers.tooltip.TooltipManager
import com.alee.managers.tooltip.WebCustomTooltip
import org.kxtra.slf4j.logger.info
import org.kxtra.slf4j.loggerfactory.getLogger
import org.kxtra.swing.component.windowAncestor
import java.awt.*
import java.util.*
import javax.swing.*

class SidePanel internal constructor() : JPanel(BorderLayout()) {

    companion object {
        const val PANEL_WIDTH = 225
        const val BAR_WIDTH = 24
        const val WIDTH = PANEL_WIDTH + BAR_WIDTH
    }

    private val tabs: SortedSet<TabButton> = TreeSet()

    private val buttons: SortedSet<BarButton> = TreeSet()

    internal val panel: JPanel

    private val buttonsBox: Box

    private val logger = getLogger()

    private var selectedTab: TabButton? = null

    init {
        panel = JPanel(BorderLayout()).apply {
            preferredSize = Dimension(PANEL_WIDTH, 0)
            minimumSize = preferredSize
            maximumSize = Dimension(PANEL_WIDTH, Int.MAX_VALUE)
            isVisible = false
        }
        buttonsBox = Box.createVerticalBox().apply {
            preferredSize = Dimension(BAR_WIDTH, 0)
            minimumSize = preferredSize
            maximumSize = Dimension(BAR_WIDTH, Int.MAX_VALUE)
        }
        add(
                Box.createHorizontalBox().apply {
                    add(buttonsBox)
                    add(panel)
                }
        )
    }

    fun add(tab: TabButton) {
        if (!tabs.add(tab)) {
            logger.info { "Cannot add $tab, it is already present" }
            return
        }
        rebuild()
    }

{'fraction_non_alphanumeric': 0.08534432018834609, 'fraction_numerical': 0.00529723366686286, 'mean_word_length': 2.2402287893231647, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2763945', 'n_tokens_mistral': 1011, 'n_tokens_neox': 963, 'n_words': 224}