Ejemplo n.º 1
0
 public BankAccountUtilsWindow(ManagerFile managerFile) :
     base(Gtk.WindowType.Toplevel)
 {
     this.Build();
     this.managerFile = managerFile;
     bankAccountCombo.FillBankAccounts(managerFile.GetObjects());
 }
Ejemplo n.º 2
0
        public SearchTransactionsWindow(ManagerFile managerFile) :
            base(Gtk.WindowType.Toplevel)
        {
            this.Build();
            this.defaultDate        = CultureInfo.CurrentCulture.DateTimeFormat.ShortDatePattern;
            startDate.Text          = defaultDate;
            endDate.Text            = defaultDate;
            this.searchTransactions = new SearchTransactions(managerFile);
            bankAccountCombo.FillBankAccounts(searchTransactions.managerFile.GetObjects());

            CellRendererToggle toggle = new Gtk.CellRendererToggle();

            Gtk.TreeViewColumn toggleColumn = new Gtk.TreeViewColumn("X", toggle, "active", 1);
            toggle.Toggled += checkToggled;
//			toggleColumn.SortColumnId = -2; // GTK_TREE_SORTABLE_UNSORTED_SORT_COLUMN_ID

            Gtk.CellRendererText dateCell   = new Gtk.CellRendererText();
            Gtk.TreeViewColumn   dateColumn = new Gtk.TreeViewColumn("Date", dateCell, "text", 2);
            dateColumn.SortColumnId = 2;
            Gtk.TreeViewColumn amountColumn = new Gtk.TreeViewColumn("Amount", new Gtk.CellRendererText(), "text", 6);
            amountColumn.SortColumnId = 3;

            Gtk.CellRendererText descriptionCell   = new Gtk.CellRendererText();
            Gtk.TreeViewColumn   descriptionColumn = new Gtk.TreeViewColumn("Description", descriptionCell, "text", 4);
            descriptionColumn.SortColumnId = 4;
            Gtk.TreeViewColumn bankAccountColumn = new Gtk.TreeViewColumn("Account", new Gtk.CellRendererText(), "text", 5);
            bankAccountColumn.SortColumnId = 5;

            transactionsTreeView.AppendColumn(toggleColumn);
            transactionsTreeView.AppendColumn(dateColumn);
            transactionsTreeView.AppendColumn(amountColumn);
            transactionsTreeView.AppendColumn(descriptionColumn);
            transactionsTreeView.AppendColumn(bankAccountColumn);
        }
Ejemplo n.º 3
0
 public MainWindow() :
     base(Gtk.WindowType.Toplevel)
 {
     this.Build();
     this.filename = ManagerFile.SelectFile(this);
     managerFile   = new ManagerFile(filename);
 }
            public List <string> ReceiptsToStrings(ManagerFile managerFile)
            {
                List <string> strings = new List <string> ();

                foreach (Receipt receipt in receipts)
                {
                    strings.Add(managerFile.GuidToText(receipt.Key));
                }
                return(strings);
            }
Ejemplo n.º 5
0
 public SearchTransactions(ManagerFile managerFile)
 {
     this.managerFile = managerFile;
 }
 public ExportManagerFile(ManagerFile managerFile)
 {
     this.managerFile = managerFile;
 }
Ejemplo n.º 7
0
 public MainDialog() : base(Gtk.WindowType.Toplevel)
 {
     this.Build();
     this.filename = ManagerFile.SelectFile(this);
     //this.filename = "/tmp/test.manager";
 }