• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.9.5/emacs-92/emacs/lisp/calendar/

Lines Matching +defs:list +defs:length

37 ;; worked today (where `timeclock-workday' specifies the length of the
93 "*The length of a work period."
99 For example, if the length of a normal workday is eight hours, and you
125 "*A function used to determine the length of today's workday.
127 called to determine what is the length of the current workday. If
131 that day has a length that is different from the norm."
231 "A list containing the last event that was recorded.
232 The format of this list is (CODE TIME PROJECT).")
355 (list (and current-prefix-arg
555 (list (floor seconds 65536)
594 (defvar timeclock-project-list nil)
601 (if (or (null str) (= (length str) 0))
611 (car timeclock-project-list)))
612 (mapcar 'list timeclock-project-list)
614 (car timeclock-project-list))))
616 (defvar timeclock-reason-list nil)
621 (mapcar 'list timeclock-reason-list)))
668 (> (length project) 0)
680 (setq timeclock-last-event (list code now project)))))
701 (list code (encode-time sec min hour mday mon year) project))))
716 (defsubst timeclock-entry-length (entry)
733 (defsubst timeclock-entry-list-length (entry-list)
734 (let ((length 0))
735 (while entry-list
736 (setq length (+ length (timeclock-entry-length (car entry-list))))
737 (setq entry-list (cdr entry-list)))
738 length))
740 (defsubst timeclock-entry-list-begin (entry-list)
741 (timeclock-entry-begin (car entry-list)))
743 (defsubst timeclock-entry-list-end (entry-list)
744 (timeclock-entry-end (car (last entry-list))))
746 (defsubst timeclock-entry-list-span (entry-list)
747 (- (timeclock-time-to-seconds (timeclock-entry-list-end entry-list))
748 (timeclock-time-to-seconds (timeclock-entry-list-begin entry-list))))
750 (defsubst timeclock-entry-list-break (entry-list)
751 (- (timeclock-entry-list-span entry-list)
752 (timeclock-entry-list-length entry-list)))
754 (defsubst timeclock-entry-list-projects (entry-list)
756 (while entry-list
757 (let ((project (timeclock-entry-project (car entry-list))))
759 (add-to-list 'projects project)
760 (setq projects (list project))))
761 (setq entry-list (cdr entry-list)))
768 (defsubst timeclock-day-length (day)
769 (timeclock-entry-list-length (cdr day)))
773 (timeclock-day-length day)))
776 (timeclock-entry-list-begin (cdr day)))
779 (timeclock-entry-list-end (cdr day)))
782 (timeclock-entry-list-span (cdr day)))
785 (timeclock-entry-list-break (cdr day)))
788 (timeclock-entry-list-projects (cdr day)))
790 (defmacro timeclock-day-list-template (func)
791 `(let ((length 0))
792 (while day-list
793 (setq length (+ length (,(eval func) (car day-list))))
794 (setq day-list (cdr day-list)))
795 length))
797 (defun timeclock-day-list-required (day-list)
798 (timeclock-day-list-template 'timeclock-day-required))
800 (defun timeclock-day-list-length (day-list)
801 (timeclock-day-list-template 'timeclock-day-length))
803 (defun timeclock-day-list-debt (day-list)
804 (timeclock-day-list-template 'timeclock-day-debt))
806 (defsubst timeclock-day-list-begin (day-list)
807 (timeclock-day-begin (car day-list)))
809 (defsubst timeclock-day-list-end (day-list)
810 (timeclock-day-end (car (last day-list))))
812 (defun timeclock-day-list-span (day-list)
813 (timeclock-day-list-template 'timeclock-day-span))
815 (defun timeclock-day-list-break (day-list)
816 (timeclock-day-list-template 'timeclock-day-break))
818 (defun timeclock-day-list-projects (day-list)
820 (while day-list
821 (let ((projs (timeclock-day-projects (car day-list))))
824 (add-to-list 'projects (car projs))
825 (setq projects (list (car projs))))
827 (setq day-list (cdr day-list)))
837 (defun timeclock-day-list (&optional log-data)
839 day-list)
841 (setq day-list (cons (cdar alist) day-list)
843 day-list))
892 where the CAR is the index, and the CDR is a list of time entries.
903 list of TIME-ENTRIES. Note that if DAY-LENGTH is nil, it means
918 timeclock-day-length
926 timeclock-day-list-required
927 timeclock-day-list-length
928 timeclock-day-list-debt
929 timeclock-day-list-begin
930 timeclock-day-list-end
931 timeclock-day-list-span
932 timeclock-day-list-break
933 timeclock-day-list-projects
935 timeclock-entry-length
941 timeclock-entry-list-length
942 timeclock-entry-list-begin
943 timeclock-entry-list-end
944 timeclock-entry-list-span
945 timeclock-entry-list-break
946 timeclock-entry-list-projects
953 `length' is the actual amount of time that was spent.
955 `debt' is the difference between required time and length. A
964 `break' is the difference between span and length.
967 list of all the projects that were worked on during a given period.
979 (let* ((log-data (list 0.0 nil nil))
992 (setq last t event (list "o" now))))
1004 (setq entry (list (cadr event) nil
1005 (and (> (length (nth 2 event)) 0)
1014 (setq day (list (and last-date-limited
1017 (setq day (list (and last-date-limited
1026 (let ((desc (and (> (length (nth 2 event)) 0)
1029 (nconc entry (list (nth 2 event))))
1032 (list t)
1033 (list nil t))))
1034 (nconc day (list entry))
1039 (cons (cons desc (list entry))
1041 (nconc (cdr proj) (list entry)))))))
1051 The result is a three element list, containing the total time
1062 ;; (setq total (+ total (- (timeclock-day-length (cdar days))
1073 (setq timeclock-project-list nil
1075 timeclock-reason-list nil
1092 (> (length (nth 2 event)) 0))
1093 (add-to-list 'timeclock-project-list (nth 2 event))
1110 (> (length (nth 2 event)) 0))
1111 (add-to-list 'timeclock-reason-list (nth 2 event)))
1141 (list accum (- elapsed timeclock-last-event-workday)
1156 "Compute the geometric mean of the values in the list L."
1181 (if (or (null project) (= (length project) 0))
1203 (setq today-len (timeclock-entry-list-length proj-data)
1209 (setq two-week-len (timeclock-entry-list-length proj-data)))
1232 (length (timeclock-day-alist log)))
1248 (let* ((day-list (timeclock-day-list))
1261 (time-in (vector (list t) (list t) (list t) (list t) (list t)))
1262 (time-out (vector (list t) (list t) (list t) (list t) (list t)))
1263 (breaks (vector (list t) (list t) (list t) (list t) (list t)))
1264 (workday (vector (list t) (list t) (list t) (list t) (list t)))
1268 (while day-list
1272 (timeclock-day-begin (car day-list))
1276 (timeclock-day-begin (car day-list))))))
1278 (list (- (timeclock-time-to-seconds
1279 (timeclock-day-begin (car day-list)))
1281 (let ((span (timeclock-day-span (car day-list)))
1282 (len (timeclock-day-length (car day-list)))
1283 (req (timeclock-day-required (car day-list))))
1284 ;; If the day's actual work length is less than
1291 (list (- (timeclock-time-to-seconds
1292 (timeclock-day-end (car day-list)))
1294 (nconc (aref breaks i) (list (- span len))))
1297 (nconc (aref workday i) (list len)))))
1299 (setq day-list (cdr day-list)))
1370 ;; make sure we know the list of reasons, projects, and have computed