2 Copyright (C) 2011 by Cuong Le <metacuong@gmail.com>
4 This program is free software: you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation, either version 3 of the License, or
7 (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
14 You should have received a copy of the GNU General Public License
15 along with this program. If not, see <http://www.gnu.org/licenses/>
20 import "amlich-hnd.js" as AmLich
21 import "xemngaytotxau.js" as NTX
28 anchors.rightMargin: 0
31 anchors.fill: parent; anchors.bottomMargin: 16
40 width:rectangle1.width-20;
46 border.color: "#b57e8f"
48 Text { x:5;y:50;text:name;color:"blue"; font.pixelSize: 20
49 font.family: "Tahoma" }
50 Text { x:5;y:50;text:getHD(idm) ; font.pixelSize: 20
51 font.family: "Tahoma"}
52 } anchors.bottomMargin: -10
64 lheight:55;idm:0;name: "";
67 lheight:30;idm:-1;name: "";
70 lheight:85;idm:1;name: "<b>Giờ Hoàng Đạo</b>";
73 lheight:55;idm:2;name: "<b>Tiết Khí</b>";
76 lheight:55;idm:3;name: "<b>Nhị Thập Bát Tú</b>";
79 lheight:80;idm:6;name: "<b>Các sao tốt</b>";
82 lheight:80;idm:7;name: "<b>Các sao xấu</b>";
85 lheight:120;idm:5;name: "<b>Ngày Tốt/Xấu</b>";
93 anchors.fill: parent;anchors.topMargin: 0;anchors.leftMargin: 0; anchors.bottomMargin: 16
95 delegate: listDelegate
101 ToolBarSingle { id: toolBar; height: 50;
104 button1Label: "Quay Về"
107 screen.state="mainscreen"
114 case 0 : return AmLich.getTHU(screen.jd)+",ngày <b>"+screen.curDay+"</b> tháng <b>"+screen.curMonth+"</b> năm <b>"+screen.curYear+"</b><br>Ngày <b>"+screen.lunarDay+"</b> tháng <b>"+screen.lunarMonth+"</b> năm <b>"+screen.lunarYear+"</b> (<b>"+screen.lunarYearInt+"</b>)";break;
115 case 1 : return screen.lunarGioHoangDao;break;
116 case 2 : return screen.lunarTietKhi();break;
117 case 3 : return NTX.sao(screen.curYear,AmLich.getLunarDate(screen.curDay,screen.curMonth,screen.curYear).jd - AmLich.getLunarDate(1,1,screen.curYear).jd);break;
118 case 5 : return NTX.luangiai(screen.curDay);break;
119 case -1: return NTX.truc(screen.lunarMonth, screen.lunarDayCanChi, screen.lunarMonthCanChi);break;//"Là ngày: <b>Thiên Lao Hắc Đạo</b> Trực: <b>Định</b>"
120 case 6: return NTX.cacsaotot(screen.lunarMonth, screen.lunarDayCanChi);break;
121 case 7: return NTX.cacsaoxau(screen.lunarMonth, screen.lunarDayCanChi);break;
126 Transition { NumberAnimation { properties: "x,y,opacity"; duration: 500; easing.type: Easing.InOutBack } }