taskjuggler 3.6.0 → 3.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (415) hide show
  1. checksums.yaml +5 -5
  2. data/CHANGELOG +51 -0
  3. data/data/css/tjreport.css +4 -0
  4. data/data/tjp.vim +21 -15
  5. data/examples/ProjectTemplate/template.tjp +7 -7
  6. data/examples/Tutorial/tutorial.tjp +1 -1
  7. data/lib/taskjuggler/Allocation.rb +1 -1
  8. data/lib/taskjuggler/AttributeBase.rb +10 -4
  9. data/lib/taskjuggler/Attributes.rb +2 -2
  10. data/lib/taskjuggler/BatchProcessor.rb +1 -1
  11. data/lib/taskjuggler/Interval.rb +10 -12
  12. data/lib/taskjuggler/Journal.rb +2 -2
  13. data/lib/taskjuggler/LogicalFunction.rb +1 -1
  14. data/lib/taskjuggler/LogicalOperation.rb +7 -4
  15. data/lib/taskjuggler/MessageHandler.rb +1 -1
  16. data/lib/taskjuggler/PTNProxy.rb +1 -1
  17. data/lib/taskjuggler/Project.rb +27 -22
  18. data/lib/taskjuggler/PropertyList.rb +7 -1
  19. data/lib/taskjuggler/PropertySet.rb +1 -1
  20. data/lib/taskjuggler/PropertyTreeNode.rb +5 -3
  21. data/lib/taskjuggler/Query.rb +3 -3
  22. data/lib/taskjuggler/RealFormat.rb +1 -1
  23. data/lib/taskjuggler/Resource.rb +2 -2
  24. data/lib/taskjuggler/ResourceScenario.rb +37 -5
  25. data/lib/taskjuggler/RichText/Snip.rb +1 -1
  26. data/lib/taskjuggler/RuntimeConfig.rb +1 -1
  27. data/lib/taskjuggler/Scoreboard.rb +5 -2
  28. data/lib/taskjuggler/Shift.rb +2 -2
  29. data/lib/taskjuggler/ShiftAssignments.rb +1 -1
  30. data/lib/taskjuggler/TaskJuggler.rb +4 -4
  31. data/lib/taskjuggler/TextParser.rb +1 -1
  32. data/lib/taskjuggler/TextParser/Scanner.rb +3 -3
  33. data/lib/taskjuggler/TimeSheets.rb +2 -2
  34. data/lib/taskjuggler/Tj3AppBase.rb +23 -9
  35. data/lib/taskjuggler/Tj3Config.rb +5 -3
  36. data/lib/taskjuggler/TjpExample.rb +3 -1
  37. data/lib/taskjuggler/TjpSyntaxRules.rb +157 -130
  38. data/lib/taskjuggler/UTF8String.rb +3 -3
  39. data/lib/taskjuggler/WorkingHours.rb +3 -3
  40. data/lib/taskjuggler/XMLElement.rb +12 -1
  41. data/lib/taskjuggler/apps/Tj3.rb +3 -1
  42. data/lib/taskjuggler/apps/Tj3Client.rb +3 -2
  43. data/lib/taskjuggler/apps/Tj3Daemon.rb +3 -1
  44. data/lib/taskjuggler/apps/Tj3Man.rb +4 -2
  45. data/lib/taskjuggler/apps/Tj3SsReceiver.rb +3 -1
  46. data/lib/taskjuggler/apps/Tj3SsSender.rb +3 -1
  47. data/lib/taskjuggler/apps/Tj3TsReceiver.rb +3 -1
  48. data/lib/taskjuggler/apps/Tj3TsSender.rb +3 -1
  49. data/lib/taskjuggler/apps/Tj3TsSummary.rb +3 -1
  50. data/lib/taskjuggler/apps/Tj3WebD.rb +3 -1
  51. data/lib/taskjuggler/deep_copy.rb +1 -1
  52. data/lib/taskjuggler/reports/CSVFile.rb +3 -3
  53. data/lib/taskjuggler/reports/ChartPlotter.rb +1 -1
  54. data/lib/taskjuggler/reports/GanttChart.rb +8 -2
  55. data/lib/taskjuggler/reports/GanttHeader.rb +11 -1
  56. data/lib/taskjuggler/reports/GanttLine.rb +6 -0
  57. data/lib/taskjuggler/reports/ICalReport.rb +1 -1
  58. data/lib/taskjuggler/reports/Report.rb +1 -1
  59. data/lib/taskjuggler/reports/ReportTableCell.rb +1 -1
  60. data/lib/taskjuggler/reports/TableReport.rb +7 -12
  61. data/lib/taskjuggler/reports/TjpExportRE.rb +1 -5
  62. data/lib/taskjuggler/version.rb +1 -0
  63. data/man/tj3.1 +130 -0
  64. data/man/tj3client.1 +145 -0
  65. data/man/tj3d.1 +93 -0
  66. data/man/tj3man.1 +76 -0
  67. data/man/tj3ss_receiver.1 +86 -0
  68. data/man/tj3ss_sender.1 +100 -0
  69. data/man/tj3ts_receiver.1 +86 -0
  70. data/man/tj3ts_sender.1 +92 -0
  71. data/man/tj3ts_summary.1 +104 -0
  72. data/man/tj3webd.1 +86 -0
  73. data/manual/Day_To_Day_Juggling +8 -8
  74. data/manual/Installation +6 -6
  75. data/manual/List_Attributes +1 -1
  76. data/manual/Rich_Text_Attributes +6 -5
  77. data/manual/Software +6 -6
  78. data/manual/TaskJuggler_Internals +4 -4
  79. data/manual/The_TaskJuggler_Syntax +5 -5
  80. data/manual/Tutorial +13 -11
  81. data/manual/html/Day_To_Day_Juggling.html +9 -9
  82. data/manual/html/Getting_Started.html +2 -2
  83. data/manual/html/How_To_Contribute.html +2 -2
  84. data/manual/html/Installation.html +8 -8
  85. data/manual/html/Intro.html +2 -2
  86. data/manual/html/List_Attributes.html +3 -3
  87. data/manual/html/Reporting_Bugs.html +2 -2
  88. data/manual/html/Rich_Text_Attributes.html +5 -5
  89. data/manual/html/Software.html +7 -7
  90. data/manual/html/TaskJuggler_2x_Migration.html +2 -2
  91. data/manual/html/TaskJuggler_Internals.html +6 -6
  92. data/manual/html/The_TaskJuggler_Syntax.html +6 -6
  93. data/manual/html/Tutorial.html +17 -14
  94. data/manual/html/account.html +4 -4
  95. data/manual/html/account.task.html +2 -2
  96. data/manual/html/accountprefix.html +2 -2
  97. data/manual/html/accountreport.html +4 -4
  98. data/manual/html/accountroot.html +3 -3
  99. data/manual/html/active.html +3 -3
  100. data/manual/html/adopt.task.html +2 -2
  101. data/manual/html/aggregate.html +2 -2
  102. data/manual/html/alert.html +3 -3
  103. data/manual/html/alertlevels.html +2 -2
  104. data/manual/html/allocate.html +3 -3
  105. data/manual/html/alphabet.html +1 -1
  106. data/manual/html/alternative.html +2 -2
  107. data/manual/html/author.html +2 -2
  108. data/manual/html/auxdir.html +2 -2
  109. data/manual/html/auxdir.report.html +3 -3
  110. data/manual/html/balance.html +3 -3
  111. data/manual/html/booking.resource.html +4 -4
  112. data/manual/html/booking.task.html +4 -4
  113. data/manual/html/caption.html +3 -3
  114. data/manual/html/cellcolor.column.html +3 -3
  115. data/manual/html/celltext.column.html +3 -3
  116. data/manual/html/center.html +3 -3
  117. data/manual/html/charge.html +2 -2
  118. data/manual/html/chargeset.html +2 -2
  119. data/manual/html/columnid.html +17 -13
  120. data/manual/html/columns.html +3 -3
  121. data/manual/html/complete.html +2 -2
  122. data/manual/html/copyright.html +2 -2
  123. data/manual/html/credits.html +2 -2
  124. data/manual/html/css/tjreport.css +4 -0
  125. data/manual/html/currency.html +2 -2
  126. data/manual/html/currencyformat.html +4 -4
  127. data/manual/html/dailymax.html +2 -2
  128. data/manual/html/dailymin.html +3 -3
  129. data/manual/html/dailyworkinghours.html +2 -2
  130. data/manual/html/date.extend.html +2 -2
  131. data/manual/html/date.html +5 -5
  132. data/manual/html/definitions.html +4 -4
  133. data/manual/html/depends.html +4 -4
  134. data/manual/html/details.html +2 -2
  135. data/manual/html/disabled.html +2 -2
  136. data/manual/html/duration.html +2 -2
  137. data/manual/html/efficiency.html +3 -3
  138. data/manual/html/effort.html +2 -2
  139. data/manual/html/effortdone.html +2 -2
  140. data/manual/html/effortleft.html +2 -2
  141. data/manual/html/email.html +2 -2
  142. data/manual/html/enabled.html +2 -2
  143. data/manual/html/end.column.html +3 -3
  144. data/manual/html/end.html +4 -4
  145. data/manual/html/end.limit.html +2 -2
  146. data/manual/html/end.report.html +3 -3
  147. data/manual/html/end.timesheet.html +3 -3
  148. data/manual/html/endcredit.html +3 -3
  149. data/manual/html/epilog.html +3 -3
  150. data/manual/html/export.html +4 -4
  151. data/manual/html/extend.html +3 -3
  152. data/manual/html/fail.html +3 -3
  153. data/manual/html/fdl.html +2 -2
  154. data/manual/html/flags.account.html +2 -2
  155. data/manual/html/flags.html +2 -2
  156. data/manual/html/flags.journalentry.html +2 -2
  157. data/manual/html/flags.report.html +3 -3
  158. data/manual/html/flags.resource.html +2 -2
  159. data/manual/html/flags.statussheet.html +2 -2
  160. data/manual/html/flags.task.html +2 -2
  161. data/manual/html/flags.timesheet.html +2 -2
  162. data/manual/html/fontcolor.column.html +3 -3
  163. data/manual/html/footer.html +3 -3
  164. data/manual/html/formats.export.html +3 -3
  165. data/manual/html/formats.html +4 -4
  166. data/manual/html/functions.html +5 -5
  167. data/manual/html/gapduration.html +2 -2
  168. data/manual/html/gaplength.html +2 -2
  169. data/manual/html/halign.center.html +2 -2
  170. data/manual/html/halign.column.html +3 -3
  171. data/manual/html/halign.left.html +2 -2
  172. data/manual/html/halign.right.html +2 -2
  173. data/manual/html/hasalert.html +2 -2
  174. data/manual/html/header.html +3 -3
  175. data/manual/html/headline.html +3 -3
  176. data/manual/html/height.html +4 -4
  177. data/manual/html/hideaccount.html +4 -4
  178. data/manual/html/hidejournalentry.html +3 -3
  179. data/manual/html/hidereport.html +3 -3
  180. data/manual/html/hideresource.html +4 -4
  181. data/manual/html/hidetask.html +4 -4
  182. data/manual/html/icalreport.html +9 -3
  183. data/manual/html/include.macro.html +3 -3
  184. data/manual/html/include.project.html +3 -3
  185. data/manual/html/include.properties.html +3 -3
  186. data/manual/html/index.html +1 -1
  187. data/manual/html/inherit.extend.html +3 -3
  188. data/manual/html/interval1.html +3 -3
  189. data/manual/html/interval2.html +3 -3
  190. data/manual/html/interval3.html +2 -2
  191. data/manual/html/interval4.html +2 -2
  192. data/manual/html/isactive.html +2 -2
  193. data/manual/html/ischildof.html +2 -2
  194. data/manual/html/isdependencyof.html +2 -2
  195. data/manual/html/isdutyof.html +2 -2
  196. data/manual/html/isfeatureof.html +2 -2
  197. data/manual/html/isleaf.html +2 -2
  198. data/manual/html/ismilestone.html +2 -2
  199. data/manual/html/isongoing.html +3 -3
  200. data/manual/html/isresource.html +2 -2
  201. data/manual/html/isresponsibilityof.html +2 -2
  202. data/manual/html/istask.html +2 -2
  203. data/manual/html/isvalid.html +2 -2
  204. data/manual/html/journalattributes.html +3 -3
  205. data/manual/html/journalentry.html +3 -3
  206. data/manual/html/journalmode.html +4 -4
  207. data/manual/html/leaveallowance.html +3 -3
  208. data/manual/html/leaves.html +3 -3
  209. data/manual/html/left.html +3 -3
  210. data/manual/html/length.html +3 -3
  211. data/manual/html/limits.allocate.html +2 -2
  212. data/manual/html/limits.html +2 -2
  213. data/manual/html/limits.resource.html +2 -2
  214. data/manual/html/limits.task.html +2 -2
  215. data/manual/html/listitem.column.html +3 -3
  216. data/manual/html/listtype.column.html +2 -2
  217. data/manual/html/loadunit.html +3 -3
  218. data/manual/html/logicalexpression.html +4 -4
  219. data/manual/html/logicalflagexpression.html +4 -4
  220. data/manual/html/macro.html +4 -4
  221. data/manual/html/managers.html +2 -2
  222. data/manual/html/mandatory.html +4 -4
  223. data/manual/html/markdate.html +69 -0
  224. data/manual/html/maxend.html +4 -4
  225. data/manual/html/maximum.html +2 -2
  226. data/manual/html/maxstart.html +2 -2
  227. data/manual/html/milestone.html +3 -3
  228. data/manual/html/minend.html +2 -2
  229. data/manual/html/minimum.html +2 -2
  230. data/manual/html/minstart.html +2 -2
  231. data/manual/html/monthlymax.html +2 -2
  232. data/manual/html/monthlymin.html +3 -3
  233. data/manual/html/navbar.html +5 -1
  234. data/manual/html/navigator.html +2 -2
  235. data/manual/html/newtask.html +3 -3
  236. data/manual/html/nikureport.html +2 -2
  237. data/manual/html/note.task.html +4 -4
  238. data/manual/html/novevents.html +68 -0
  239. data/manual/html/now.html +4 -4
  240. data/manual/html/number.extend.html +2 -2
  241. data/manual/html/numberformat.html +3 -3
  242. data/manual/html/onend.html +2 -2
  243. data/manual/html/onstart.html +2 -2
  244. data/manual/html/opennodes.html +3 -3
  245. data/manual/html/outputdir.html +3 -3
  246. data/manual/html/overtime.booking.html +2 -2
  247. data/manual/html/period.column.html +2 -2
  248. data/manual/html/period.limit.html +2 -2
  249. data/manual/html/period.report.html +3 -3
  250. data/manual/html/period.task.html +2 -2
  251. data/manual/html/persistent.html +3 -3
  252. data/manual/html/precedes.html +5 -5
  253. data/manual/html/priority.html +4 -4
  254. data/manual/html/priority.timesheet.html +3 -3
  255. data/manual/html/project.html +4 -4
  256. data/manual/html/projectid.html +2 -2
  257. data/manual/html/projectid.task.html +3 -3
  258. data/manual/html/projectids.html +2 -2
  259. data/manual/html/projection.html +2 -2
  260. data/manual/html/prolog.html +3 -3
  261. data/manual/html/properties.html +3 -3
  262. data/manual/html/purge.html +3 -3
  263. data/manual/html/rate.html +2 -2
  264. data/manual/html/rate.resource.html +2 -2
  265. data/manual/html/rawhtmlhead.html +4 -4
  266. data/manual/html/reference.extend.html +2 -2
  267. data/manual/html/remaining.html +3 -3
  268. data/manual/html/replace.html +2 -2
  269. data/manual/html/reportprefix.html +2 -2
  270. data/manual/html/resource.html +3 -3
  271. data/manual/html/resourceattributes.html +2 -2
  272. data/manual/html/resourceprefix.html +2 -2
  273. data/manual/html/resourcereport.html +5 -5
  274. data/manual/html/resourceroot.html +4 -4
  275. data/manual/html/resources.limit.html +2 -2
  276. data/manual/html/responsible.html +2 -2
  277. data/manual/html/richtext.extend.html +2 -2
  278. data/manual/html/right.html +3 -3
  279. data/manual/html/rollupaccount.html +4 -4
  280. data/manual/html/rollupresource.html +4 -4
  281. data/manual/html/rolluptask.html +4 -4
  282. data/manual/html/scale.column.html +2 -2
  283. data/manual/html/scenario.html +3 -3
  284. data/manual/html/scenario.ical.html +3 -3
  285. data/manual/html/scenarios.export.html +2 -2
  286. data/manual/html/scenarios.html +3 -3
  287. data/manual/html/scenariospecific.extend.html +2 -2
  288. data/manual/html/scheduled.html +2 -2
  289. data/manual/html/scheduling.html +6 -6
  290. data/manual/html/schedulingmode.html +2 -2
  291. data/manual/html/select.html +4 -4
  292. data/manual/html/selfcontained.html +3 -3
  293. data/manual/html/shift.allocate.html +2 -2
  294. data/manual/html/shift.html +3 -3
  295. data/manual/html/shift.resource.html +4 -4
  296. data/manual/html/shift.task.html +2 -2
  297. data/manual/html/shift.timesheet.html +2 -2
  298. data/manual/html/shifts.allocate.html +2 -2
  299. data/manual/html/shifts.resource.html +2 -2
  300. data/manual/html/shifts.task.html +3 -3
  301. data/manual/html/shorttimeformat.html +3 -3
  302. data/manual/html/sloppy.booking.html +2 -2
  303. data/manual/html/sloppy.projection.html +2 -2
  304. data/manual/html/sortaccounts.html +3 -3
  305. data/manual/html/sortjournalentries.html +3 -3
  306. data/manual/html/sortresources.html +3 -3
  307. data/manual/html/sorttasks.html +3 -3
  308. data/manual/html/start.column.html +3 -3
  309. data/manual/html/start.html +4 -4
  310. data/manual/html/start.limit.html +2 -2
  311. data/manual/html/start.report.html +3 -3
  312. data/manual/html/startcredit.html +3 -3
  313. data/manual/html/status.statussheet.html +2 -2
  314. data/manual/html/status.timesheet.html +2 -2
  315. data/manual/html/statussheet.html +2 -2
  316. data/manual/html/statussheetreport.html +3 -3
  317. data/manual/html/strict.projection.html +2 -2
  318. data/manual/html/summary.html +2 -2
  319. data/manual/html/supplement.html +2 -2
  320. data/manual/html/supplement.resource.html +2 -2
  321. data/manual/html/supplement.task.html +2 -2
  322. data/manual/html/tagfile.html +3 -3
  323. data/manual/html/task.html +3 -3
  324. data/manual/html/task.statussheet.html +3 -3
  325. data/manual/html/task.timesheet.html +2 -2
  326. data/manual/html/taskattributes.html +2 -2
  327. data/manual/html/taskprefix.html +2 -2
  328. data/manual/html/taskreport.html +5 -5
  329. data/manual/html/taskroot.export.html +2 -2
  330. data/manual/html/taskroot.html +3 -3
  331. data/manual/html/text.extend.html +2 -2
  332. data/manual/html/textreport.html +5 -5
  333. data/manual/html/timeformat.html +4 -4
  334. data/manual/html/timeformat1.html +2 -2
  335. data/manual/html/timeformat2.html +2 -2
  336. data/manual/html/timeoff.nikureport.html +2 -2
  337. data/manual/html/timesheet.html +3 -3
  338. data/manual/html/timesheetreport.html +3 -3
  339. data/manual/html/timezone.export.html +2 -2
  340. data/manual/html/timezone.html +2 -2
  341. data/manual/html/timezone.report.html +3 -3
  342. data/manual/html/timezone.shift.html +2 -2
  343. data/manual/html/timingresolution.html +2 -2
  344. data/manual/html/title.column.html +2 -2
  345. data/manual/html/title.html +3 -3
  346. data/manual/html/toc.html +157 -143
  347. data/manual/html/tooltip.column.html +3 -3
  348. data/manual/html/tracereport.html +8 -8
  349. data/manual/html/trackingscenario.html +3 -3
  350. data/manual/html/treelevel.html +2 -2
  351. data/manual/html/vacation.html +2 -2
  352. data/manual/html/vacation.resource.html +2 -2
  353. data/manual/html/vacation.shift.html +2 -2
  354. data/manual/html/warn.html +4 -4
  355. data/manual/html/weeklymax.html +2 -2
  356. data/manual/html/weeklymin.html +3 -3
  357. data/manual/html/weekstartsmonday.html +2 -2
  358. data/manual/html/weekstartssunday.html +2 -2
  359. data/manual/html/width.column.html +2 -2
  360. data/manual/html/width.html +4 -4
  361. data/manual/html/work.html +3 -3
  362. data/manual/html/workinghours.project.html +3 -3
  363. data/manual/html/workinghours.resource.html +2 -2
  364. data/manual/html/workinghours.shift.html +2 -2
  365. data/manual/html/yearlyworkingdays.html +2 -2
  366. data/spec/ProjectBroker_spec.rb +6 -6
  367. data/spec/StatusSheets_spec.rb +1 -1
  368. data/spec/TimeSheets_spec.rb +1 -1
  369. data/taskjuggler.gemspec +7 -7
  370. data/tasks/changelog.rake +2 -0
  371. data/tasks/gem.rake +3 -0
  372. data/tasks/help2man.rake +18 -0
  373. data/tasks/kate.rake +2 -0
  374. data/tasks/manual.rake +2 -0
  375. data/tasks/test.rake +5 -0
  376. data/tasks/vim.rake +2 -0
  377. data/test/TestSuite/Export-Reports/refs/AccountReport.tjp +0 -1
  378. data/test/TestSuite/Export-Reports/refs/AdoptedTasks.tjp +0 -2
  379. data/test/TestSuite/Export-Reports/refs/AlertLevels.tjp +0 -1
  380. data/test/TestSuite/Export-Reports/refs/Allocate-1.tjp +0 -1
  381. data/test/TestSuite/Export-Reports/refs/AutoID.tjp +0 -1
  382. data/test/TestSuite/Export-Reports/refs/AutoMacros.tjp +0 -1
  383. data/test/TestSuite/Export-Reports/refs/Currencyformat.tjp +0 -1
  384. data/test/TestSuite/Export-Reports/refs/CustomAttributes.tjp +0 -2
  385. data/test/TestSuite/Export-Reports/refs/Depends1.tjp +0 -1
  386. data/test/TestSuite/Export-Reports/refs/Durations.tjp +0 -1
  387. data/test/TestSuite/Export-Reports/refs/Efficiency.tjp +0 -1
  388. data/test/TestSuite/Export-Reports/refs/Gap.tjp +0 -3
  389. data/test/TestSuite/Export-Reports/refs/Include.tjp +0 -1
  390. data/test/TestSuite/Export-Reports/refs/Journal.tjp +0 -1
  391. data/test/TestSuite/Export-Reports/refs/Macro-1.tjp +0 -1
  392. data/test/TestSuite/Export-Reports/refs/Macro-2.tjp +0 -2
  393. data/test/TestSuite/Export-Reports/refs/Macro-3.tjp +0 -1
  394. data/test/TestSuite/Export-Reports/refs/Manager.tjp +0 -1
  395. data/test/TestSuite/Export-Reports/refs/Milestone.tjp +0 -2
  396. data/test/TestSuite/Export-Reports/refs/Numberformat.tjp +0 -1
  397. data/test/TestSuite/Export-Reports/refs/Precedes1.tjp +0 -1
  398. data/test/TestSuite/Export-Reports/refs/Project.tjp +0 -1
  399. data/test/TestSuite/Export-Reports/refs/ProjectIDs.tjp +0 -3
  400. data/test/TestSuite/Export-Reports/refs/Reports.tjp +0 -1
  401. data/test/TestSuite/Export-Reports/refs/Resource.tjp +0 -1
  402. data/test/TestSuite/Export-Reports/refs/ResourceRoot.tjp +0 -1
  403. data/test/TestSuite/Export-Reports/refs/RollupResource.tjp +0 -1
  404. data/test/TestSuite/Export-Reports/refs/Scenario.tjp +0 -2
  405. data/test/TestSuite/Export-Reports/refs/Timezone.tjp +0 -1
  406. data/test/TestSuite/Export-Reports/refs/Vacation.tjp +0 -1
  407. data/test/TestSuite/Export-Reports/refs/navigator.tjp +0 -4
  408. data/test/TestSuite/Export-Reports/refs/template.tjp +0 -6
  409. data/test/TestSuite/Export-Reports/refs/textreport.tjp +0 -1
  410. data/test/TestSuite/Export-Reports/refs/tutorial.tjp +0 -8
  411. data/test/TestSuite/Syntax/Correct/Booking.tjp +1 -1
  412. data/test/TestSuite/Syntax/Correct/Currencyformat.tjp +1 -1
  413. data/test/TestSuite/Syntax/Correct/tutorial.tjp +5 -0
  414. data/test/test_ProjectFileScanner.rb +8 -8
  415. metadata +43 -10
@@ -230,7 +230,7 @@ class TaskJuggler
230
230
  private
231
231
 
232
232
  def checkLevel(level)
233
- if level.is_a?(Fixnum)
233
+ if level.is_a?(Integer)
234
234
  if level < 0 || level > 5
235
235
  raise ArgumentError, "Unsupported level #{level}"
236
236
  end
@@ -104,7 +104,7 @@ class TaskJuggler
104
104
  end
105
105
 
106
106
  # Return the 'index' attributes of this property, prefixed by the 'index'
107
- # attributes of all its parents. The result is an Array of Fixnums.
107
+ # attributes of all its parents. The result is an Array of Integers.
108
108
  def getIndicies
109
109
  idcs = []
110
110
  p = self
@@ -78,6 +78,7 @@ class TaskJuggler
78
78
  'currencyFormat' => RealFormat.new([ '-', '', '', ',', 2 ]),
79
79
  'dailyworkinghours' => 8.0,
80
80
  'end' => nil,
81
+ 'markdate' => nil,
81
82
  'flags' => [],
82
83
  'journal' => Journal.new,
83
84
  'limits' => nil,
@@ -126,7 +127,7 @@ class TaskJuggler
126
127
  false, false, false, true ],
127
128
  [ 'projection', 'Projection Mode', BooleanAttribute,
128
129
  true, false, false, false ],
129
- [ 'seqno', 'No', FixnumAttribute,
130
+ [ 'seqno', 'No', IntegerAttribute,
130
131
  false, false, false, nil ],
131
132
  ]
132
133
  attrs.each { |a| @scenarios.addAttributeType(AttributeDefinition.new(*a)) }
@@ -139,7 +140,7 @@ class TaskJuggler
139
140
  false, false, false, "" ],
140
141
  [ 'id', 'ID', StringAttribute,
141
142
  false, false, false, nil ],
142
- [ 'index', 'Index', FixnumAttribute,
143
+ [ 'index', 'Index', IntegerAttribute,
143
144
  false, false, false, -1 ],
144
145
  [ 'leaves', 'Leaves', LeaveListAttribute,
145
146
  true, true, true, LeaveList.new ],
@@ -147,7 +148,7 @@ class TaskJuggler
147
148
  false, false, false, nil ],
148
149
  [ 'replace', 'Replace', BooleanAttribute,
149
150
  true, false, true, false ],
150
- [ 'seqno', 'No', FixnumAttribute,
151
+ [ 'seqno', 'No', IntegerAttribute,
151
152
  false, false, false, nil ],
152
153
  [ 'timezone', 'Time Zone', StringAttribute,
153
154
  true, true, true, TjTime.timeZone ],
@@ -170,13 +171,13 @@ class TaskJuggler
170
171
  false, false, true, [] ],
171
172
  [ 'id', 'ID', StringAttribute,
172
173
  false, false, false, nil ],
173
- [ 'index', 'Index', FixnumAttribute,
174
+ [ 'index', 'Index', IntegerAttribute,
174
175
  false, false, false, -1 ],
175
176
  [ 'flags', 'Flags', FlagListAttribute,
176
177
  true, false, true, [] ],
177
178
  [ 'name', 'Name', StringAttribute,
178
179
  false, false, false, nil ],
179
- [ 'seqno', 'No', FixnumAttribute,
180
+ [ 'seqno', 'No', IntegerAttribute,
180
181
  false, false, false, nil ],
181
182
  [ 'tree', 'Tree Index', StringAttribute,
182
183
  false, false, false, "" ]
@@ -201,7 +202,7 @@ class TaskJuggler
201
202
  false, false, true, [] ],
202
203
  [ 'efficiency','Efficiency', FloatAttribute,
203
204
  true, false, true, 1.0 ],
204
- [ 'effort', 'Total Effort', FixnumAttribute,
205
+ [ 'effort', 'Total Effort', IntegerAttribute,
205
206
  false, false, true, 0 ],
206
207
  [ 'email', 'Email', StringAttribute,
207
208
  false, false, false, nil ],
@@ -209,7 +210,7 @@ class TaskJuggler
209
210
  false, false, false, [] ],
210
211
  [ 'flags', 'Flags', FlagListAttribute,
211
212
  true, false, true, [] ],
212
- [ 'index', 'Index', FixnumAttribute,
213
+ [ 'index', 'Index', IntegerAttribute,
213
214
  false, false, false, -1 ],
214
215
  [ 'leaveallowances', 'Leave Allowances', LeaveAllowanceListAttribute,
215
216
  true, false, true, LeaveAllowanceList.new ],
@@ -223,7 +224,7 @@ class TaskJuggler
223
224
  true, true, true, 0.0 ],
224
225
  [ 'reports', 'Reports', ResourceListAttribute,
225
226
  false, false, true, [] ],
226
- [ 'seqno', 'No', FixnumAttribute,
227
+ [ 'seqno', 'No', IntegerAttribute,
227
228
  false, false, false, nil ],
228
229
  [ 'shifts', 'Shifts', ShiftAssignmentsAttribute,
229
230
  true, false, true, nil ],
@@ -264,9 +265,9 @@ class TaskJuggler
264
265
  false, false, true, 0 ],
265
266
  [ 'effort', 'Effort', DurationAttribute,
266
267
  false, false, true, 0 ],
267
- [ 'effortdone', 'Completed Effort', FixnumAttribute,
268
+ [ 'effortdone', 'Completed Effort', IntegerAttribute,
268
269
  false, false, true, nil ],
269
- [ 'effortleft', 'Remaining Effort', FixnumAttribute,
270
+ [ 'effortleft', 'Remaining Effort', IntegerAttribute,
270
271
  false, false, true, nil ],
271
272
  [ 'end', 'End', DateAttribute,
272
273
  false, false, true, nil ],
@@ -284,7 +285,7 @@ class TaskJuggler
284
285
  false, false, true, nil ],
285
286
  [ 'id', 'ID', StringAttribute,
286
287
  false, false, false, nil ],
287
- [ 'index', 'Index', FixnumAttribute,
288
+ [ 'index', 'Index', IntegerAttribute,
288
289
  false, false, false, -1 ],
289
290
  [ 'length', 'Length', DurationAttribute,
290
291
  false, false, true, 0 ],
@@ -308,7 +309,7 @@ class TaskJuggler
308
309
  false, false, true, 0.0 ],
309
310
  [ 'precedes', 'Following tasks', DependencyListAttribute,
310
311
  true, false, true, [] ],
311
- [ 'priority', 'Priority', FixnumAttribute,
312
+ [ 'priority', 'Priority', IntegerAttribute,
312
313
  true, true, true, 500 ],
313
314
  [ 'projectid', 'Project ID', SymbolAttribute,
314
315
  true, true, true, nil ],
@@ -318,7 +319,7 @@ class TaskJuggler
318
319
  true, false, true, false ],
319
320
  [ 'projectionmode', 'Projection Mode', BooleanAttribute,
320
321
  true, false, true, false ],
321
- [ 'seqno', 'No', FixnumAttribute,
322
+ [ 'seqno', 'No', IntegerAttribute,
322
323
  false, false, false, nil ],
323
324
  [ 'shifts', 'Shifts', ShiftAssignmentsAttribute,
324
325
  true, false, true, nil ],
@@ -361,6 +362,8 @@ class TaskJuggler
361
362
  true, false, false, KeywordArray.new([ '*' ]) ],
362
363
  [ 'end', 'End', DateAttribute,
363
364
  true, true, false, nil ],
365
+ [ 'markdate', 'Markdate', DateAttribute,
366
+ true, true, false, nil ],
364
367
  [ 'epilog', 'Epilog', RichTextAttribute,
365
368
  true, false, false, nil ],
366
369
  [ 'flags', 'Flags', FlagListAttribute,
@@ -383,11 +386,11 @@ class TaskJuggler
383
386
  true, false, false, nil ],
384
387
  [ 'hideTask', 'Hide Task', LogicalExpressionAttribute,
385
388
  true, false, false, nil ],
386
- [ 'height', 'Height', FixnumAttribute,
389
+ [ 'height', 'Height', IntegerAttribute,
387
390
  false, false, false, 480 ],
388
391
  [ 'id', 'ID', StringAttribute,
389
392
  false, false, false, nil ],
390
- [ 'index', 'Index', FixnumAttribute,
393
+ [ 'index', 'Index', IntegerAttribute,
391
394
  false, false, false, -1 ],
392
395
  [ 'interactive', 'Interactive', BooleanAttribute,
393
396
  false, false, false, false ],
@@ -429,7 +432,7 @@ class TaskJuggler
429
432
  true, false, false, [ 0 ] ],
430
433
  [ 'selfcontained', 'Selfcontained', BooleanAttribute,
431
434
  true, false, false, false ],
432
- [ 'seqno', 'No', FixnumAttribute,
435
+ [ 'seqno', 'No', IntegerAttribute,
433
436
  false, false, false, nil ],
434
437
  [ 'shortTimeFormat', 'Short Time Format', StringAttribute,
435
438
  true, true, false, nil ],
@@ -461,8 +464,10 @@ class TaskJuggler
461
464
  false, false, false, "" ],
462
465
  [ 'weekStartsMonday', 'Week Starts Monday', BooleanAttribute,
463
466
  true, true, false, false ],
464
- [ 'width', 'Width', FixnumAttribute,
465
- true, false, false, 640 ]
467
+ [ 'width', 'Width', IntegerAttribute,
468
+ true, false, false, 640 ],
469
+ [ 'novevents', 'No vevents in icalreports', BooleanAttribute,
470
+ true, false, false, false ]
466
471
  ]
467
472
  attrs.each { |a| @reports.addAttributeType(AttributeDefinition.new(*a)) }
468
473
 
@@ -560,7 +565,7 @@ class TaskJuggler
560
565
  #
561
566
  # Return the Scenario with the given _id_ or _index_.
562
567
  def scenario(arg)
563
- if arg.is_a?(Fixnum)
568
+ if arg.is_a?(Integer)
564
569
  @scenarios.each do |sc|
565
570
  return sc if sc.sequenceNo - 1 == arg
566
571
  end
@@ -866,7 +871,7 @@ class TaskJuggler
866
871
  # isWorkingTime(startTime, endTime) -> true or false
867
872
  # isWorkingTime(interval) -> true or false
868
873
  #
869
- # Return true if the slot or interval is withing globally defined working
874
+ # Return true if the slot or interval is within globally defined working
870
875
  # time or false if not. If the argument is a TimeInterval, all slots of
871
876
  # the interval must be working time to return true as result. Global work
872
877
  # time means, no global leaves defined and the slot lies within a
@@ -874,7 +879,7 @@ class TaskJuggler
874
879
  def isWorkingTime(*args)
875
880
  # Normalize argument(s) to TimeInterval
876
881
  if args.length == 1
877
- if args[0].is_a?(Fixnum) || args[0].is_a?(Bignum)
882
+ if args[0].is_a?(Integer)
878
883
  return @scoreboard[args[0]].nil?
879
884
  elsif args[0].is_a?(TjTime)
880
885
  return @scoreboard[dateToIdx(args[0])].nil?
@@ -969,7 +974,7 @@ class TaskJuggler
969
974
 
970
975
  def collectTimeOffIntervals(iv, minDuration)
971
976
  @scoreboard.collectIntervals(iv, minDuration) do |val|
972
- val.is_a?(Fixnum) && (val & 0x3E) != 0
977
+ val.is_a?(Integer) && (val & 0x3E) != 0
973
978
  end
974
979
  end
975
980
 
@@ -3,7 +3,7 @@
3
3
  #
4
4
  # = PropertyList.rb -- The TaskJuggler III Project Management Software
5
5
  #
6
- # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014
6
+ # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2019
7
7
  # by Chris Schlaeger <cs@taskjuggler.org>
8
8
  #
9
9
  # This program is free software; you can redistribute it and/or modify
@@ -271,10 +271,16 @@ class TaskJuggler
271
271
 
272
272
  @query.property = a
273
273
  @query.process
274
+ unless @query.ok
275
+ fatal "List sort failed: #{@query.errorMessage}"
276
+ end
274
277
  aVal = @query.to_sort
275
278
 
276
279
  @query.property = b
277
280
  @query.process
281
+ unless @query.ok
282
+ fatal "List sort failed: #{@query.errorMessage}"
283
+ end
278
284
  bVal = @query.to_sort
279
285
  else
280
286
  # In case we don't have a query, we use the static mechanism.
@@ -51,7 +51,7 @@ class TaskJuggler
51
51
  [
52
52
  [ 'id', 'ID', StringAttribute, false, false, false, '' ],
53
53
  [ 'name', 'Name', StringAttribute, false, false, false, '' ],
54
- [ 'seqno', 'Seq. No', FixnumAttribute, false, false, false, 0 ]
54
+ [ 'seqno', 'Seq. No', IntegerAttribute, false, false, false, 0 ]
55
55
  ].each { |a| addAttributeType(AttributeDefinition.new(*a)) }
56
56
  end
57
57
 
@@ -3,7 +3,7 @@
3
3
  #
4
4
  # = PropertyTreeNode.rb -- The TaskJuggler III Project Management Software
5
5
  #
6
- # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014
6
+ # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2019
7
7
  # by Chris Schlaeger <cs@taskjuggler.org>
8
8
  #
9
9
  # This program is free software; you can redistribute it and/or modify
@@ -331,7 +331,7 @@ class TaskJuggler
331
331
  end
332
332
 
333
333
  # Return the 'index' attributes of this property, prefixed by the 'index'
334
- # attributes of all its parents. The result is an Array of Fixnums.
334
+ # attributes of all its parents. The result is an Array of Integers.
335
335
  def getIndicies
336
336
  idcs = []
337
337
  p = self
@@ -702,11 +702,13 @@ class TaskJuggler
702
702
  res += '-' * 75 + "\n"
703
703
  end
704
704
 
705
+ alias to_str to_s
706
+
705
707
  # Many PropertyTreeNode functions are scenario specific. These functions are
706
708
  # provided by the class *Scenario classes. In case we can't find a function
707
709
  # called for the base class we try to find it in corresponding *Scenario
708
710
  # class.
709
- def method_missing(func, scenarioIdx, *args, &block)
711
+ def method_missing(func, scenarioIdx = 0, *args, &block)
710
712
  @data[scenarioIdx].send(func, *args, &block)
711
713
  end
712
714
 
@@ -81,7 +81,7 @@ class TaskJuggler
81
81
  end
82
82
 
83
83
  def startIdx=(idx)
84
- if idx.is_a?(Fixnum)
84
+ if idx.is_a?(Integer)
85
85
  @startIdx = idx
86
86
  @start = @project.idxToDate(idx)
87
87
  else
@@ -99,7 +99,7 @@ class TaskJuggler
99
99
  end
100
100
 
101
101
  def endIdx=(idx)
102
- if idx.is_a?(Fixnum)
102
+ if idx.is_a?(Integer)
103
103
  @endIdx = idx
104
104
  @end = @project.idxToDate(idx)
105
105
  else
@@ -239,7 +239,7 @@ class TaskJuggler
239
239
  @attr ? @attr.to_s(self) : (@rti ? @rti.to_s : (@string || ''))
240
240
  end
241
241
 
242
- # Return the result of the Query as Fixnum or Float. The result may be
242
+ # Return the result of the Query as Integer or Float. The result may be
243
243
  # nil.
244
244
  def to_num
245
245
  @attr ? @attr.to_num : @numerical
@@ -24,7 +24,7 @@ class TaskJuggler
24
24
  # thousandsSeparator: Separator used after 3 integer digits. (String)
25
25
  # fractionSeparator: Separator used between the inter part and the
26
26
  # fractional part. (String)
27
- # fractionDigits: Number of fractional digits to show. (Fixnum)
27
+ # fractionDigits: Number of fractional digits to show. (Integer)
28
28
  class RealFormat
29
29
 
30
30
  attr_reader :signPrefix, :signSuffix, :thousandsSeparator,
@@ -3,7 +3,7 @@
3
3
  #
4
4
  # = Resource.rb -- The TaskJuggler III Project Management Software
5
5
  #
6
- # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014
6
+ # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2019
7
7
  # by Chris Schlaeger <cs@taskjuggler.org>
8
8
  #
9
9
  # This program is free software; you can redistribute it and/or modify
@@ -37,7 +37,7 @@ class TaskJuggler
37
37
  # provided by the class ResourceScenario. In case we can't find a
38
38
  # function called for the Resource class we try to find it in
39
39
  # ResourceScenario.
40
- def method_missing(func, scenarioIdx, *args, &block)
40
+ def method_missing(func, scenarioIdx = 0, *args, &block)
41
41
  @data[scenarioIdx].method(func).call(*args, &block)
42
42
  end
43
43
 
@@ -20,7 +20,7 @@ class TaskJuggler
20
20
  def initialize(resource, scenarioIdx, attributes)
21
21
  super
22
22
 
23
- # Scoreboard may be nil, a Task, or a bit vector encoded as a Fixnum
23
+ # Scoreboard may be nil, a Task, or a bit vector encoded as an Integer
24
24
  # nil: Value has not been determined yet.
25
25
  # Task: A reference to a Task object
26
26
  # Bit 0: Reserved
@@ -279,6 +279,23 @@ class TaskJuggler
279
279
  query.string = query.scaleLoad(val)
280
280
  end
281
281
 
282
+ # Compute a list of the annual leave days within the period specified by
283
+ # the _query_. The result is a list of dates and how much of that day was
284
+ # taken.
285
+ def query_annualleavelist(query)
286
+ iv_list = collectLeaveIntervals(Interval.new(query.start, query.end), :annual)
287
+ iv_list.map! do |iv|
288
+ # The interval is at most one working day. We list the date of that
289
+ # day.
290
+ day = iv.start.strftime(@project['timeFormat'])
291
+ # And how much of the working day was taken. A full working day is
292
+ # 1.0, a half working day 0.5.
293
+ days = (iv.end - iv.start) / (60 * 60 * @project['dailyworkinghours'])
294
+ "#{day} (#{'%.1f' % days})"
295
+ end
296
+ query.assignList(iv_list)
297
+ end
298
+
282
299
  def query_annualleavebalance(query)
283
300
  if @property.leaf?
284
301
  leave = getLeave(query.startIdx, query.endIdx, :annual)
@@ -685,7 +702,22 @@ class TaskJuggler
685
702
  initScoreboard if @scoreboard.nil?
686
703
 
687
704
  @scoreboard.collectIntervals(iv, minDuration) do |val|
688
- val.is_a?(Fixnum) && (val & 0x3E) != 0
705
+ val.is_a?(Integer) && (val & 0x3E) != 0
706
+ end
707
+ end
708
+
709
+ # Return a list of scoreboard intervals that are at least _minDuration_ long
710
+ # and only contain leave slots of the given type. The result is an Array of
711
+ # [ start, end ] TjTime values.
712
+ def collectLeaveIntervals(iv, type)
713
+ # Time-off intervals are only useful for leaf resources. Group resources
714
+ # would just default to the global working hours.
715
+ return [] unless @property.leaf?
716
+
717
+ initScoreboard if @scoreboard.nil?
718
+
719
+ @scoreboard.collectIntervals(iv, 60 * 60) do |val|
720
+ val.is_a?(Integer) && (val & 0x3E) == (Leave::Types[type] << 2)
689
721
  end
690
722
  end
691
723
 
@@ -723,7 +755,7 @@ class TaskJuggler
723
755
  # leave.
724
756
  def getLeaveSlots(startIdx, endIdx, type)
725
757
  countSlots(startIdx, endIdx) do |val|
726
- val.is_a?(Fixnum) && (val & 0x3E) == (Leave::Types[type] << 2)
758
+ val.is_a?(Integer) && (val & 0x3E) == (Leave::Types[type] << 2)
727
759
  end
728
760
  end
729
761
 
@@ -739,7 +771,7 @@ class TaskJuggler
739
771
  def getTimeOffSlots(startIdx, endIdx)
740
772
  countSlots(startIdx, endIdx) do |val|
741
773
  # Bit 1 needs to be unset and the leave bits must not be 0.
742
- val.is_a?(Fixnum) && (val & 0x2) == 0 && (val & 0x3C) != 0
774
+ val.is_a?(Integer) && (val & 0x2) == 0 && (val & 0x3C) != 0
743
775
  end
744
776
  end
745
777
 
@@ -900,7 +932,7 @@ class TaskJuggler
900
932
  initScoreboard unless @scoreboard
901
933
 
902
934
  val = @scoreboard[sbIdx]
903
- return true unless val.is_a?(Fixnum)
935
+ return true unless val.is_a?(Integer)
904
936
 
905
937
  leave_type = (val >> 2) & 0xF
906
938
  leave_type < Leave::Types[:unemployed]
@@ -27,7 +27,7 @@ class TaskJuggler
27
27
 
28
28
  # Create a RichTextSnip object. _document_ is a reference to the
29
29
  # RichTextDocument. _fileName_ is the name of the structured text file
30
- # using RichText syntax. _sectionCounter_ is an 3 item Fixnum Array. These
30
+ # using RichText syntax. _sectionCounter_ is an 3 item Integer Array. These
31
31
  # 3 numbers are used to store the section counters over multiple
32
32
  # RichTextSnip objects.
33
33
  def initialize(document, fileName, sectionCounter)
@@ -45,7 +45,7 @@ class RuntimeConfig
45
45
  def configure(object, section)
46
46
  debug("Configuring object of type #{object.class}")
47
47
  sections = section.split('.')
48
- p = @config
48
+ return false unless (p = @config)
49
49
  sections.each do |sec|
50
50
  p = p['_' + sec]
51
51
  unless p
@@ -3,7 +3,7 @@
3
3
  #
4
4
  # = Scoreboard.rb -- The TaskJuggler III Project Management Software
5
5
  #
6
- # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014
6
+ # Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2019
7
7
  # by Chris Schlaeger <cs@taskjuggler.org>
8
8
  #
9
9
  # This program is free software; you can redistribute it and/or modify
@@ -175,9 +175,12 @@ class TaskJuggler
175
175
  end
176
176
 
177
177
  def inspect
178
+ s = ''
178
179
  0.upto(@sb.length - 1) do |i|
179
- puts "#{idxToDate(i)}: #{@sb[i]}"
180
+ s << "#{idxToDate(i)}: #{@sb[i]}"
180
181
  end
182
+
183
+ s
181
184
  end
182
185
 
183
186
  end