# Path: l5r/util/log.py
# def log_setup(base_path, base_name):


import l5r.api as api
import l5r.models as models
import l5r.widgets as widgets
import l5r.api.character
from l5r.util import log
from PyQt5 import QtCore, QtGui, QtWidgets
            self.cb_perk.addItem(p.name, p)

    def on_perk_select(self, text=''):
        if self.edit_mode:
            return

        self.item = None
        self.cb_rank.clear()

        selected = self.cb_perk.currentIndex()
        if selected < 0:
            return
        perk = self.cb_perk.itemData(selected)

        self.update_book(perk)

        self.perk_id = perk.id
        self.perk_nm = perk.name

        # get perk rule
        self.perk_rule = perk.rule

        # fill description
        if perk.desc:
            self.tx_notes.setPlainText(perk.desc)

        # populate ranks
        for rank in perk.ranks:
            self.cb_rank.addItem(self.tr("Rank %d") % rank.id, rank)


# Path: l5r/util/log.py
# def log_setup(base_path, base_name):


# Path: l5r/dialogs/perkseldlg.py
import l5r.api as api
import l5r.models as models
import l5r.widgets as widgets
import l5r.api.character
from l5r.util import log
from PyQt5 import QtCore, QtGui, QtWidgets

            self.cb_perk.addItem(p.name, p)

    def on_perk_select(self, text=''):
        if self.edit_mode:
            return

        self.item = None
        self.cb_rank.clear()

        selected = self.cb_perk.currentIndex()
        if selected < 0:
            return
        perk = self.cb_perk.itemData(selected)

        self.update_book(perk)

        self.perk_id = perk.id
        self.perk_nm = perk.name

        # get perk rule
        self.perk_rule = perk.rule

        # fill description
        if perk.desc:
            self.tx_notes.setPlainText(perk.desc)

        # populate ranks
        for rank in perk.ranks:
            self.cb_rank.addItem(self.tr("Rank %d") % rank.id, rank)


    def on_rank_select(self, text=''):