Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision
  • pr/podio_1
  • ci_image_update
  • pr/dd4hep_01_24
  • master
  • 90-support-fastsim-and-gflash
  • multi-threaded-npsim
  • 82-set-charge-by-pdg-id-in-hepmc-reader
  • 79-npsim-gun-shoudl-have-gun-etamin-and-gun-etamax
  • occ_7.5
  • v0.2.0
  • v0.3.0
  • v0.3.1
  • v0.3.2
  • v0.4.0
  • v0.5.0
  • v0.6.0
  • v0.7.0
  • v0.8.0
  • v0.9.0
  • v1.0.0
  • v1.1.0
  • v1.2.0
  • v1.2.1
  • v1.2.2
  • v1.2.3
  • v1.2.4
  • v1.3.0
  • v1.3.1
  • v1.3.2
  • v1.4.0
  • v1.4.1
31 results

Target

Select target project
No results found
Select Git revision
  • emcal_gap
  • master
  • crystal
  • ZDC
  • Digit
  • HCAL_detector
  • whit-master-patch-58257
  • tooling
  • new_ci_runner
  • sieic_vis
  • beamline
11 results
Show changes

Commits on Source 487

387 additional commits have been omitted to prevent performance issues.
420 files
+ 29894
146826
Compare changes
  • Side-by-side
  • Inline

Files

.clang-format

0 → 100644
+58 −0
Original line number Original line Diff line number Diff line
---
BasedOnStyle:  Chromium
BreakConstructorInitializersBeforeComma: true
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: true
AlignConsecutiveDeclarations: true
AlignEscapedNewlines: Right
AlignOperands:   true
AlignTrailingComments: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: true
BraceWrapping:
  AfterClass:      false
  AfterControlStatement: false
  AfterEnum:       false
  AfterFunction:   false
  AfterNamespace:  false
  AfterObjCDeclaration: false
  AfterStruct:     false
  AfterUnion:      false
  AfterExternBlock: false
  BeforeCatch:     false
  BeforeElse:      false
  IndentBraces:    false
  SplitEmptyFunction: true
  SplitEmptyRecord: true
  SplitEmptyNamespace: true
ConstructorInitializerAllOnOneLineOrOnePerLine: true
Cpp11BracedListStyle: true
ColumnLimit: 120
Standard: Cpp11
#SpaceBeforeParens: ControlStatements
SpaceAfterControlStatementKeyword: true
BinPackArguments: true
BinPackParameters: true
PenaltyBreakAssignment: 2
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 60
PointerAlignment: Left
PointerBindsToType: true
NamespaceIndentation: All
ReflowComments:  true
SortIncludes:    true
SortUsingDeclarations: true
SpacesBeforeTrailingComments: 1
...
+16 −0
Original line number Original line Diff line number Diff line
FROM  eicweb.phy.anl.gov:4567/containers/eic_container/jug_dev:testing

LABEL maintainer="Whitney Armstrong <warmstrong@anl.gov>" \
      name="npdet" \
      group="EIC/NPDet" \
      march="native" \
      basedist="ubuntu" \
      base="eic_container" \
      version="0.2"

RUN cd /tmp             \
      && git clone  https://eicweb.phy.anl.gov/EIC/NPDet.git \
      && mkdir -p NPDet/build && cd NPDet/build \
      && cmake ../. -DCMAKE_CXX_STANDARD=17 \
      && make -j30  && make -j4 install \
      && cd /tmp && rm -rf /tmp/NPDet 
+206 −0
Original line number Original line Diff line number Diff line
# import config.
# You can change the default config with `make cnf="config_special.env" build`
cnf ?= config.env
include $(cnf)
# exports variables in config.env as environment variables
export $(shell sed 's/=.*//' $(cnf))



SHELL = bash
# grep the version from the mix file
VERSION=$(shell bash version.sh)
TAG_VERSION=$(VERSION)

# help will output the help for each task
# thanks to https://marmelab.com/blog/2016/02/29/auto-documented-makefile.html
.PHONY: help

help: ## This help.
	@awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST)

.DEFAULT_GOAL := help

# ==========================================================================
#
build: ## build the image
	docker build -t $(APP_NAME) .

build-nc: ## Build the container without caching (from scratch)
	docker build --no-cache -t $(APP_NAME) .

build-alt: ## build the container for various machine architectures (broadwell, haswell, knl)
	@echo 'building for architecture: $(ALT_NAME)'
	docker build -t $(APP_NAME)_$(ALT_NAME) -f Dockerfile.$(ALT_NAME) .

build-alt-nc: ## build the container for various machine architectures (broadwell, haswell, knl)
	@echo 'build-alt-nc: building for architecture: $(ALT_NAME)'
	docker build --no-cache -t $(APP_NAME)_$(ALT_NAME) -f Dockerfile.$(ALT_NAME) .

# ==========================================================================
#
run: ## Run container on port configured in `config.env`
	docker run -i -t --rm --env-file=./config.env -p=$(PORT):$(PORT) --name="$(APP_NAME)" $(REPO)/$(APP_NAME):$(TAG_VERSION)

up: build run ## Run container on port configured in `config.env` (Alias to run)

stop: ## Stop and remove a running container
	docker stop $(APP_NAME); docker rm $(APP_NAME)

# ==========================================================================
#
tag: tag-latest tag-version #tag-version ## Generate container tags for the `{version}` and `latest` tags

tag-latest: ## Generate container `{version}` tag
	@echo 'create tag latest'
	#docker tag $(APP_NAME)   $(REPO)/$(APP_NAME):latest

tag-version: ## Generate container `latest` tag
	@echo 'creating tag $(APP_NAME):$(VERSION)'
	docker tag $(APP_NAME):latest $(APP_NAME):$(VERSION)

tag-alt: tag-alt-latest # tag-alt-version ## Generate container tags for the `{version}` ans `latest` tags

tag-alt-latest: ## Generate container `{version}` tag
	@echo 'create tag latest'
	#docker tag $(APP_NAME)_$(ALT_NAME) $(REPO)/$(APP_NAME)_$(ALT_NAME):latest

tag-alt-version: ## Generate container `{version}` tag
	@echo 'create tag latest'
	docker tag $(APP_NAME)_$(ALT_NAME) $(REG_NAME)/$(REPO)/$(APP_NAME)_$(ALT_NAME):$(VERSION)

# ==========================================================================
#
login: ## Auto login to AWS-ECR unsing aws-cli
	@docker login -u ${CI_REGISTRY_USER} -p ${CI_REGISTRY_PASSWORD} ${CI_REGISTRY}
	echo "Login COMPLETE"

release-latest: build login publish-latest ## Make a release by building and publishing the `{version}` ans `latest` tagged containers to ECR

release: build-nc publish cleanup## Make a release by building and publishing the `{version}` ans `latest` tagged containers to ECR

release-cached: build publish ## Make a release by building and publishing the `{version}` ans `latest` tagged containers to ECR

cleanup:
	@echo "cleaning up"
	docker rmi  $(APP_NAME):latest 

publish: login publish-latest publish-version #publish-version ## Publish the `{version}` ans `latest` tagged containers to ECR
	@echo "Publishing done"


publish-latest: ## Publish the `latest` taged container to ECR
	@echo 'publish latest to $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)'
	docker tag $(APP_NAME):latest $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):latest
	docker push $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):latest
	docker rmi  $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):latest

publish-version: ## Publish the `{version}` taged container to ECR
	@echo 'publish latest to $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):$(VERSION)'
	docker tag $(APP_NAME):latest $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):$(VERSION)
	docker push $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):$(VERSION)
	docker rmi  $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):$(VERSION)

push: login ## push after login @echo 'push latest to $(REG_NAME)/$(REPO)/$(APP_NAME):latest'
	docker tag  $(APP_NAME):latest $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):latest
	docker push $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):latest

# ==========================================================================
#
release-alt: build-alt publish-alt ## Make a release by building and publishing the `{version}` ans `latest` tagged containers to ECR

publish-alt: login publish-alt-latest #publish-alt-version ## Publish the `{version}` ans `latest` tagged containers to ECR

push-alt: login tag-alt-latest ## push after login 
	#docker push $(REG_NAME)/$(REPO)/$(APP_NAME)_$(ALT_NAME):latest
	docker push $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):latest

publish-alt-latest: #tag-alt-latest ## Publish the `latest` taged container to ECR
	#docker push $(REG_NAME)/$(REPO)/$(APP_NAME)_$(ALT_NAME):latest
	docker tag $(APP_NAME)_$(ALT_NAME):latest $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):latest
	docker push $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):latest
	docker rmi $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):latest

publish-alt-version: tag-alt-version ## Publish the `latest` taged container to ECR
	#docker push $(REG_NAME)/$(REPO)/$(APP_NAME)_$(ALT_NAME):$(VERSION)
	docker push $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):$(VERSION)

# ==========================================================================
#

login-dockerhub: ## login to hub.docker.com
	@echo 'docker hub login :'
	docker login 

push-dockerhub: build #publish-version ## Publish the `{version}` ans `latest` tagged containers to ECR
	@echo '$(DH_ORG)/$(APP_NAME):$(TAG_VERSION)'
	docker push $(DH_ORG)/$(APP_NAME):latest
	#docker push $(DH_ORG)/$(APP_NAME):$(VERSION)

publish-dockerhub: build tag #publish-version ## Publish the `{version}` ans `latest` tagged containers to ECR
	@echo '$(DH_ORG)/$(APP_NAME):$(TAG_VERSION)'
	docker push $(DH_ORG)/$(APP_NAME):latest
	#docker push $(DH_ORG)/$(APP_NAME):$(VERSION)

# ==========================================================================
#
clean-tags:
	docker rmi  $(REPO)/$(APP_NAME):latest || true
	docker rmi  $(GL_GROUP)/$(APP_NAME):latest || true
	docker rmi  $(GL_REG_GROUP)/$(APP_NAME):latest || true
	docker rmi  $(REG_NAME)/$(REPO)/$(APP_NAME):latest   || true
	docker rmi  $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):latest || true
	docker rmi  $(REPO)/$(APP_NAME)_$(ALT_NAME):latest || true
	docker rmi  $(GL_GROUP)/$(APP_NAME)_$(ALT_NAME):latest || true
	docker rmi  $(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):latest || true
	docker rmi  $(REG_NAME)/$(REPO)/$(APP_NAME)_$(ALT_NAME):latest   || true
	docker rmi  $(REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):latest || true

clean:
	docker rmi $(REPO_NAME)/$(APP_NAME) || true
	docker rmi $(REPO_NAME)/$(APP_NAME):$(TAG_VERSION) || true
	docker rmi $(REPO_NAME)/$(APP_NAME):$(VERSION) || true
	docker rmi $(REPO)/$(APP_NAME) || true
	docker rmi $(REPO)/$(APP_NAME):$(TAG_VERSION) || true
	docker rmi $(REPO)/$(APP_NAME):$(VERSION) || true
	docker rmi $(REG_NAME)/$(REPO)/$(APP_NAME):latest || true  
	docker rmi $(REG_NAME)/$(REPO)/$(APP_NAME):$(TAG_VERSION) || true  
	docker rmi $(REG_NAME)/$(REPO)/$(APP_NAME) || true  
	docker rmi $(DH_ORG)/$(APP_NAME) || true
	docker rmi $(DH_ORG)/$(APP_NAME):$(TAG_VERSION) || true
	docker rmi $(DH_ORG)/$(APP_NAME):$(VERSION) || true
	docker rmi $(GL_REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):latest || true  
	docker rmi $(GL_REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME):$(VERSION) || true  
	docker rmi $(GL_REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME) || true  
	docker rmi $(GL_REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):latest || true  
	docker rmi $(GL_REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):$(VERSION) || true  
	docker rmi $(GL_REG_NAME)/$(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME) || true  
	docker rmi $(GL_REG_GROUP)/$(APP_NAME) || true  
	docker rmi $(GL_REG_GROUP)/$(APP_NAME):$(VERSION) || true  
	docker rmi $(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME) || true  
	docker rmi $(GL_REG_GROUP)/$(APP_NAME)_$(ALT_NAME):$(VERSION) || true  
	docker rmi $(GL_REG_NAME)/$(REG_USER)/$(APP_NAME) || true  
	docker rmi $(GL_REG_NAME)/$(REG_USER)/$(APP_NAME):$(VERSION) || true  
	#docker rmi $(APP_NAME) || true

version: ## Output the current version
	@echo $(VERSION)

# ==========================================================================
#
info: ## Output the current version
	@echo 'VERSION      = $(VERSION)     '
	@echo 'REG_USER     = $(REG_USER)    '
	@echo 'REG_NAME     = $(REG_NAME)    '
	@echo 'ALT_NAME     = $(ALT_NAME)    '
	@echo 'APP_NAME     = $(APP_NAME)    '
	@echo 'REPO_NAME    = $(REPO_NAME)   '
	@echo 'DH_ORG       = $(DH_ORG)      '
	@echo 'GL_GROUP     = $(GL_GROUP)    '
	@echo 'GL_REG_GROUP = $(GL_REG_GROUP)'
	@echo 'GL_REG_NAME  = $(GL_REG_NAME) '
	@echo 'REPO         = $(REPO)        '
	@echo 'TAG_VERSION  = $(TAG_VERSION) '

ls: ## list all docker images 
	docker images 
+20 −0
Original line number Original line Diff line number Diff line
# Port to run the container 

REG_HOST  ?= eicweb.phy.anl.gov
REG_NAME  ?= eicweb.phy.anl.gov:4567
REG_PORT  ?= 4567
REG_URL   ?= https://$(REG_HOST)

APP_NAME     = npdet
REPO_NAME    = npdet

DH_ORG       = hallac

GL_GROUP     = eic
GL_REG_GROUP = eic/npdet
GL_REG_NAME  = $(REG_NAME)




+26 −0
Original line number Original line Diff line number Diff line
# INSTALL
# - copy the files deploy.env, config.env, version.sh and Makefile to your repo
# - replace the vars in deploy.env
# - define the version script

# Build the container
make build

# Build and publish the container
make release

# Publish a container to AWS-ECR.
# This includes the login to the repo
make publish

# Run the container
make run

# Build an run the container
make up

# Stop the running container
make stop

# Build the container with differnt config and deploy file
make cnf=another_config.env dpl=another_deploy.env build
 No newline at end of file
+4 −0
Original line number Original line Diff line number Diff line
#!/bin/bash

cat ../../VERSION
+42 −6
Original line number Original line Diff line number Diff line
*.pcm
# Compiled Object files
*.slo
*.lo
*.o

# Compiled Dynamic libraries
*.so
*.so
*.d
*.dylib
*.root

*.slcio
# Compiled Static libraries
*.stp
*.lai
*.la
*.a

# build trees
build/*
doc/doxygen_output
DEBUG*/*
BUILD*/*
RELEASE*/*
TEST*/*

# cmake
CMakeCache.txt
CMakeFiles
Makefile
cmake_install.cmake
install_manifest.txt


# vim 
# vim 
~*
*.swp
*.swp
*.swo

# python
__pycache__/
*.py[cod]
*$py.class
.ipynb_checkpoints

##
*.d
*.pcm
*.root
*.hepmc
+76 −19
Original line number Original line Diff line number Diff line
image: eicweb.phy.anl.gov:4567/containers/image_recipes/dd4hep_base:latest   
image: eicweb.phy.anl.gov:4567/containers/eic_container/jug_dev:testing


stages:
stages:
  - build
  - build
  - containerize
  - test
  - deploy


before_script:
.eicweb:
  - pwd
  rules:
  - ls -lrth /usr/local/bin
    - if: '$CI_SERVER_HOST == "eicweb.phy.anl.gov"'

.documentation:
  rules:
    - if: '$CI_SERVER_HOST != "eicweb.phy.anl.gov" && $CI_COMMIT_BRANCH == "master"' 


compile:
compile:
  extends: .eicweb
  stage: build
  script:
    - bash bin/do_build
  artifacts:
    when: always
    paths:
      - install/
      - build/test_result_*.xml
    reports:
      junit: build/test_result_*.xml

test_npsim:
  extends: .eicweb
  needs: ["compile"]
  stage: test
  script:
    - mkdir -p test_files/
    - LD_LIBRARY_PATH=install/lib:$LD_LIBRARY_PATH install/bin/npsim --compactFile examples/gem_tracker_disc.xml --enableGun --numberOfEvents 10 --outputFile test_files/test_npsim.root
    - rootls -t test_files/test_npsim.root
  artifacts:
    expire_in: 1 days
    paths: 
      - test_files/

gen_doxygen_src:
  stage: build
  extends: .documentation
  script:
    - mkdir build && cd build && cmake ../. -DCMAKE_INSTALL_PREFIX=../install 
  artifacts:
    paths:
    - build/src/dd4pod/src
    - build/src/dd4pod/dd4pod

rtd_sphinx_build:
  stage: build
  stage: build
  image: eicweb.phy.anl.gov:4567/containers/image_recipes/dd4hep_base:latest  
  extends: .documentation
    #image: eicweb.phy.anl.gov:4567/containers/eic_container/rtd_builder
  image: eicweb.phy.anl.gov:4567/containers/image_recipes/ubuntu_dind:latest
  script:
    - apt-get update && apt-get install -y python3-sphinx python3-pip 
    - pip3 install sphinx && pip3 install sphinx_rtd_theme 
    - cd docs && pip3 install -r requirements.txt && make html 
  artifacts:
    paths:
    - docs/_build/html

pages:
  stage: deploy
  extends: .documentation
  image: eicweb.phy.anl.gov:4567/containers/eic_container/alpine
  needs: ['gen_doxygen_src','rtd_sphinx_build']
  script:
  script:
    - ./bin/do_build
    - apk update && apk add doxygen  graphviz ttf-ubuntu-font-family
#    - . /usr/local/bin/thisroot.sh
    - mkdir -p public && cp -r  docs/_build/html/* public/.
#    - . /usr/local/bin/thisdd4hep.sh
    - cd doc && doxygen Doxyfile && mv doxygen_output/html ../public/ref_doc && cd ..
#    - . /usr/local/bin/geant4.sh
  artifacts:
#    - mkdir install
    paths:
#    - mkdir build
    - public
#    - cd build

#    - cmake .. -DCMAKE_INSTALL_PREFIX=../install
staging:
#    - make -j4
  stage: deploy

  rules:
trigger:
    - if: '$CI_SERVER_HOST == "eicweb.phy.anl.gov" && $CI_COMMIT_BRANCH == "master"' 
  stage: containerize
  trigger: EIC/juggler
  script: curl -X POST -F token=8806e69cdc802d752413e8a31554a2 -F ref=master https://eicweb.phy.anl.gov/api/v4/projects/290/trigger/pipeline

+2 −0
Original line number Original line Diff line number Diff line
terminal:
  image: eicweb.phy.anl.gov:4567/containers/eic_container/jug_dev:testing

.readthedocs.yml

0 → 100644
+25 −0
Original line number Original line Diff line number Diff line
# .readthedocs.yml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Build documentation in the docs/ directory with Sphinx
sphinx:
  configuration: docs/conf.py

# Build documentation with MkDocs
#mkdocs:
#  configuration: mkdocs.yml

# Optionally build your docs in additional formats such as PDF
formats:
  - pdf

# Optionally set the version of Python and requirements required to build your docs
python:
  version: 3.7
  install:
    - requirements: docs/requirements.txt
+94 −43
Original line number Original line Diff line number Diff line
cmake_minimum_required(VERSION 3.2 FATAL_ERROR)
cmake_minimum_required(VERSION 3.12 FATAL_ERROR)
project(NPDet VERSION 0.1.0 LANGUAGES CXX)


# Add library source directory name that appear in ./src
# CMP0074: find_package() uses <PackageName>_ROOT variables
set(NPDet_LIB_NAMES
cmake_policy(SET CMP0074 NEW)
    GenericDetectors
    )


# Add executable source directory name that appear in ./src
project(NPDet
set(NPDet_EXE_NAMES
  VERSION 1.2.0
    )
  LANGUAGES CXX)


# Add concept detector names
# C++ standard
set(NPDet_CONCEPT_NAMES
set(CMAKE_CXX_STANDARD 17)
    eRHIC
set(CMAKE_CXX_STANDARD 17 CACHE STRING "Set the C++ standard to be used")
    JLEIC
if(NOT CMAKE_CXX_STANDARD MATCHES "17|20|23")
    SiEIC
  message(FATAL_ERROR "Unsupported C++ standard: ${CMAKE_CXX_STANDARD}")
    SoLID
endif()
    )
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)

# Build type
if (NOT CMAKE_BUILD_TYPE)
  set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Build type configuration" FORCE)
  message(STATUS "Setting default build type: ${CMAKE_BUILD_TYPE}")
endif()

# Error on all warnings
if(NOT CMAKE_BUILD_TYPE STREQUAL "Release")
  #FIXME not ready for this...
  #add_compile_options(-Wall -Wextra -Werror -pedantic)
endif()

# Export compile commands as json for run-clang-tidy
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)

option(BUILD_DATA_MODEL "build the dd4pod datamodel" ON)

set(USE_GEOCAD ON CACHE BOOL "build the geocad library. Requires opencascade")


# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# set default install prefix and build type
# set default install prefix, build type, C++ standard
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
    set(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT FALSE)
    set(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT FALSE)
    set(CMAKE_INSTALL_PREFIX "/usr/local" CACHE PATH "..." FORCE)
    set(CMAKE_INSTALL_PREFIX "/usr/local" CACHE PATH "..." FORCE)
@@ -29,42 +46,72 @@ if(NOT CMAKE_BUILD_TYPE)
    set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "..." FORCE)
    set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "..." FORCE)
endif()
endif()


if(NOT CMAKE_CXX_STANDARD)
    set(CMAKE_CXX_STANDARD 17 CACHE STRING "...." FORCE)
    set(CMAKE_CXX_STANDARD_REQUIRED ON)
    set(CMAKE_CXX_EXTENSIONS OFF)
endif()

include(GNUInstallDirs)

# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# load additional OS dependent settings
# load additional OS dependent settings
include(cmake/os.cmake)
include(cmake/os.cmake)
include(cmake/root.cmake)

set(PODIO "$ENV{PODIO}/lib/podio/cmake")
set(CMAKE_MODULE_PATH CMAKE_MODULE_PATH PODIO)



#----------------------------------------------------------------------------
#----------------------------------------------------------------------------
# Find Libraries
# Find Libraries
find_package( DD4hep REQUIRED COMPONENTS DDCore DDG4 )
#----------------------------------------------------------------------------
# PODIO
find_package(podio 0.14.1 REQUIRED )
include_directories(${podio_INCLUDE_DIR})

# DD4hep
find_package( DD4hep 1.18 REQUIRED COMPONENTS DDCore DDG4 )
include(${DD4hep_DIR}/cmake/DD4hep.cmake)
include(${DD4hep_DIR}/cmake/DD4hepBuild.cmake)
dd4hep_configure_output()
dd4hep_set_compiler_flags()

# Opencascade
if(USE_GEOCAD)
  find_package(OpenCASCADE)
endif()


#-----------------------------------------
# libfmt
# add the library sub directories
find_package(fmt REQUIRED)
foreach(aSharedLib ${NPDet_LIB_NAMES})
    add_subdirectory("src/${aSharedLib}")
endforeach(aSharedLib)


# add the executable sub directories
#-----------------------------------------
foreach(anExeName ${NPDet_EXE_NAMES})
# catch2 unit testing
    add_subdirectory("src/${anExeName}")
enable_testing()
endforeach(anExeName)
Include(FetchContent)
FetchContent_Declare(
  Catch2
  GIT_REPOSITORY https://github.com/catchorg/Catch2.git
  GIT_TAG        v2.13.1)
FetchContent_MakeAvailable(Catch2)
#target_link_libraries(tests Catch2::Catch2)


# add the concept detector sub directories
#-----------------------------------------
foreach(aConceptName ${NPDet_CONCEPT_NAMES})
# add the library sub directories
    add_subdirectory("src/ConceptDetectors/${aConceptName}")
add_subdirectory(src/detectors)
endforeach(aConceptName)
add_subdirectory(src/plugins)
add_subdirectory(src/dd4pod)
add_subdirectory(src/geocad)
add_subdirectory(src/config)
add_subdirectory(src/tools)


#----------------------------------------------------------------------------
#----------------------------------------------------------------------------
# install examples
# install examples
set(NPDet_EXAMPLES 
#set(NPDet_EXAMPLES
    )
#    )
install(FILES ${NPDet_EXAMPLES}
#install(FILES ${NPDet_EXAMPLES}
    DESTINATION "${CMAKE_INSTALL_PREFIX}/share/${PROJECT_NAME}/examples"
#    DESTINATION "${CMAKE_INSTALL_PREFIX}/share/${PROJECT_NAME}/examples"
    )
#    )

#----------------------------------------------------------------------------
# Add the config tool/script directory
add_subdirectory(src/config)
add_subdirectory(src/tools)


#----------------------------------------------------------------------------
#----------------------------------------------------------------------------
# Install and export targets
# Install and export targets
@@ -81,7 +128,7 @@ CONFIGURE_PACKAGE_CONFIG_FILE(
    cmake/NPDetConfig.cmake.in
    cmake/NPDetConfig.cmake.in
    ${CMAKE_CURRENT_BINARY_DIR}/NPDetConfig.cmake
    ${CMAKE_CURRENT_BINARY_DIR}/NPDetConfig.cmake
    INSTALL_DESTINATION lib/NPDet
    INSTALL_DESTINATION lib/NPDet
    PATH_VARS TARGETS_INSTALL_PATH
    PATH_VARS CMAKE_INSTALL_INCLUDEDIR CMAKE_INSTALL_LIBDIR TARGETS_INSTALL_PATH
    )
    )


write_basic_package_version_file("NPDetConfigVersion.cmake"
write_basic_package_version_file("NPDetConfigVersion.cmake"
@@ -94,3 +141,7 @@ install(FILES
    ${CMAKE_CURRENT_BINARY_DIR}/NPDetConfigVersion.cmake
    ${CMAKE_CURRENT_BINARY_DIR}/NPDetConfigVersion.cmake
    DESTINATION lib/NPDet
    DESTINATION lib/NPDet
    )
    )

install(PROGRAMS
  scripts/sanitize_hepmc3.py DESTINATION bin RENAME sanitize_hepmc3
    )
+19 −67
Original line number Original line Diff line number Diff line
NPDet - Nuclear Physics Detector Library
NPdet - Nuclear Physics Detector Library
========================================
========================================


  * [Overview](#overview)
A collection of detectors for simulating and building Nuclear Physics experiments.
  * [Installation](#installation)
    + [Dependencies](#dependencies)
    + [Building](#building)
    + [Getting Started](#getting-started)
      - [Using the detector library](#using-the-detector-library)
      - [Adding a detector to the library](#adding-a-detector-to-the-library)
  * [Libraries](#libraries)
    + [Generic Detectors](#generic-detectors)
    + [Concept-Detectors](#concept-detectors)
      - [SiEIC](#sieic)
      - [JLEIC](#jleic)
      - [SoLID](#solid)
      - [clas12](#clas12)
      - [eRHIC](#erhic)
  * [Related Projects and Useful Links](#related-projects-and-useful-links)


Overview
Overview
--------
--------
@@ -28,21 +13,32 @@ simulation and reconstruction easier by providing a set of flexible
concept-detector can be created.
concept-detector can be created.




Documentation
-------------

- [User Manual found here](https://eic.phy.anl.gov/npdet/)
- [Reference API documentation](https://eic.phy.anl.gov/npdet/ref_doc)

Writing documentation:
- [restructured text syntax .rst](https://thomas-cokelaer.info/tutorials/sphinx/rest_syntax.html)

### Tutorials



Installation
Installation
------------
------------


### Dependencies
### Singularity Container


The following are needed before building `NPDet`
The easiest way to use this library is the with the  [eic_container](https://eicweb.phy.anl.gov/containers/eic_container/).

### Building


The following are needed before building `NPDet`
* [DD4hep](https://github.com/AIDAsoft/DD4hep)
* [DD4hep](https://github.com/AIDAsoft/DD4hep)
* [ROOT](https://root.cern.ch)
* [ROOT](https://root.cern.ch)
* [GEANT4](http://geant4.cern.ch)
* [GEANT4](http://geant4.cern.ch)



### Building

```
```
git clone https://eicweb.phy.anl.gov/EIC/NPDet.git
git clone https://eicweb.phy.anl.gov/EIC/NPDet.git
mkdir npdet_build && cd npdet_build
mkdir npdet_build && cd npdet_build
@@ -51,54 +47,10 @@ make -j4
make install
make install
```
```


### Getting Started

#### Using the detector library

Checkout the [`examples`](examples/README.md) directory for a quick start
on how to use the input.

#### Adding a detector to the library

Todo


Libraries
---------

### Generic Detectors

[more details about Generic Detectors](src/GenericDetectors/README.md)

### Concept-Detectors

#### SiEIC

[more details about SiEIC](src/ConceptDetectors/SiEIC/README.md)

#### JLEIC

[more details about JLEIC](src/ConceptDetectors/JLEIC/README.md)

#### SoLID

[more details about JLEIC](src/ConceptDetectors/SoLID/README.md)

#### clas12

[more details about JLEIC](src/ConceptDetectors/clas12/README.md)

#### eRHIC

[more details about eRHIC](src/ConceptDetectors/eRHIC/README.md)


Related Projects and Useful Links
Related Projects and Useful Links
---------------------------------
---------------------------------


- [nprec](https://eicweb.phy.anl.gov/EIC/nprec)
- [FCCSW](https://github.com/HEP-FCC/FCCSW),
- [lcgeo](https://github.com/iLCSoft/lcgeo)
- [FCCSW](https://github.com/HEP-FCC/FCCSW), [fcc](http://fccsw.web.cern.ch/fccsw/)
- [PODIO](https://github.com/HEP-FCC/podio)
- [PODIO](https://github.com/HEP-FCC/podio)
- [HepMC3](https://gitlab.cern.ch/hepmc/HepMC3.git)
- [HepMC3](https://gitlab.cern.ch/hepmc/HepMC3.git)

VERSION

0 → 100644
+1 −0
Original line number Original line Diff line number Diff line
1.2.0
+4 −8
Original line number Original line Diff line number Diff line
#!/bin/bash
#!/bin/bash
ps
cmake -Bbuild -S. -DCMAKE_CXX_STANDARD=17 -DCMAKE_INSTALL_PREFIX=install
source /usr/local/bin/thisroot.sh
cmake --build build -j30
source /usr/local/bin/thisdd4hep.sh
cmake --build build --target test
source /usr/local/bin/geant4.sh
cmake --install build
mkdir build
cd build
cmake ../. -DCMAKE_INSTALL_PREFIX=/usr/local
make -j10
Original line number Original line Diff line number Diff line

@PACKAGE_INIT@
@PACKAGE_INIT@


include("@PACKAGE_TARGETS_INSTALL_PATH@")
include("${CMAKE_CURRENT_LIST_DIR}/NPDetTargets.cmake")

set_and_check(NPDet_INCLUDE_DIR "@PACKAGE_CMAKE_INSTALL_INCLUDEDIR@")
set_and_check(NPDet_LIBRARY_DIR "@PACKAGE_CMAKE_INSTALL_LIBDIR@")
#set_and_check(NPDet_PYTHON_DIR "@PACKAGE_NPDet_PYTHON_INSTALLDIR@")

include(CMakeFindDependencyMacro)
find_dependency(ROOT @ROOT_VERSION@)



check_required_components(NPDet)
check_required_components(NPDet)
+34 −0
Original line number Original line Diff line number Diff line
# - Try to find OpenCASCADE libraries
### Does not test what version has been found,though
### that could be done by parsing Standard_Version.hxx

# Once done, this will define
#  OCC_FOUND - true if OCC has been found
#  OCC_INCLUDE_DIR - the OCC include dir
#  OCC_LIBRARIES (not cached) - full path of OCC libraries

set(_occdirs ${CASROOT} ${CASS_DIR} $ENV{CASROOT} /opt/occ)

find_path(OCC_INCLUDE_DIR
          NAMES Standard_Real.hxx
          HINTS ${_occdirs} /usr/include/opencascade /usr/include/oce
          PATH_SUFFIXES inc
          DOC "Specify the directory containing Standard_Real.hxx")

foreach(_libname ${OCC_FIND_COMPONENTS})
  list(APPEND OCC_REQUIRED_LIBRARIES OCC_${_libname}_LIBRARY)
  find_library(OCC_${_libname}_LIBRARY $
              NAMES ${_libname}
              HINTS ${_occdirs}
              PATH_SUFFIXES lib)
  if(OCC_${_libname}_LIBRARY)
    list(APPEND OCC_LIBRARIES ${OCC_${_libname}_LIBRARY})
  endif()
endforeach()

# handle the QUIETLY and REQUIRED arguments and set OCC_FOUND to TRUE if
# all listed variables are TRUE

include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(OCC DEFAULT_MSG OCC_INCLUDE_DIR ${OCC_REQUIRED_LIBRARIES})
mark_as_advanced(OCC_INCLUDE_DIR ${OCC_REQUIRED_LIBRARIES})

doc/Doxyfile

0 → 100644
+2486 −0

File added.

Preview size limit exceeded, changes collapsed.

doc/Doxyfile2

0 → 100644
+2494 −0

File added.

Preview size limit exceeded, changes collapsed.

Original line number Original line Diff line number Diff line
/*
 You probably do not need to edit this at all.

 Add some SmartMenus required styles not covered in Bootstrap 3's default CSS.
 These are theme independent and should work with any Bootstrap 3 theme mod.
*/
/* sub menus arrows on desktop */
.navbar-nav:not(.sm-collapsible) ul .caret {
	position: absolute;
	right: 0;
	margin-top: 6px;
	margin-right: 15px;
	border-top: 4px solid transparent;
	border-bottom: 4px solid transparent;
	border-left: 4px dashed;
}
.navbar-nav:not(.sm-collapsible) ul a.has-submenu {
	padding-right: 30px;
}
/* make sub menu arrows look like +/- buttons in collapsible mode */
.navbar-nav.sm-collapsible .caret, .navbar-nav.sm-collapsible ul .caret {
	position: absolute;
	right: 0;
	margin: -3px 15px 0 0;
	padding: 0;
	width: 32px;
	height: 26px;
	line-height: 24px;
	text-align: center;
	border-width: 1px;
 	border-style: solid;
}
.navbar-nav.sm-collapsible .caret:before {
	content: '+';
	font-family: monospace;
	font-weight: bold;
}
.navbar-nav.sm-collapsible .open > a > .caret:before {
	content: '-';
}
.navbar-nav.sm-collapsible a.has-submenu {
	padding-right: 50px;
}
/* revert to Bootstrap's default carets in collapsible mode when the "data-sm-skip-collapsible-behavior" attribute is set to the ul.navbar-nav */
.navbar-nav.sm-collapsible[data-sm-skip-collapsible-behavior] .caret, .navbar-nav.sm-collapsible[data-sm-skip-collapsible-behavior] ul .caret {
	position: static;
	margin: 0 0 0 2px;
	padding: 0;
	width: 0;
	height: 0;
	border-top: 4px dashed;
	border-right: 4px solid transparent;
	border-bottom: 0;
	border-left: 4px solid transparent;
}
.navbar-nav.sm-collapsible[data-sm-skip-collapsible-behavior] .caret:before {
	content: '' !important;
}
.navbar-nav.sm-collapsible[data-sm-skip-collapsible-behavior] a.has-submenu {
	padding-right: 15px;
}
/* scrolling arrows for tall menus */
.navbar-nav span.scroll-up, .navbar-nav span.scroll-down {
	position: absolute;
	display: none;
	visibility: hidden;
	height: 20px;
	overflow: hidden;
	text-align: center;
}
.navbar-nav span.scroll-up-arrow, .navbar-nav span.scroll-down-arrow {
	position: absolute;
	top: -2px;
	left: 50%;
	margin-left: -8px;
	width: 0;
	height: 0;
	overflow: hidden;
	border-top: 7px dashed transparent;
	border-right: 7px dashed transparent;
	border-bottom: 7px solid;
	border-left: 7px dashed transparent;
}
.navbar-nav span.scroll-down-arrow {
	top: 6px;
	border-top: 7px solid;
	border-right: 7px dashed transparent;
	border-bottom: 7px dashed transparent;
	border-left: 7px dashed transparent;
}
/* add more indentation for 2+ level sub in collapsible mode - Bootstrap normally supports just 1 level sub menus */
.navbar-nav.sm-collapsible ul .dropdown-menu > li > a,
.navbar-nav.sm-collapsible ul .dropdown-menu .dropdown-header {
	padding-left: 35px;
}
.navbar-nav.sm-collapsible ul ul .dropdown-menu > li > a,
.navbar-nav.sm-collapsible ul ul .dropdown-menu .dropdown-header {
	padding-left: 45px;
}
.navbar-nav.sm-collapsible ul ul ul .dropdown-menu > li > a,
.navbar-nav.sm-collapsible ul ul ul .dropdown-menu .dropdown-header {
	padding-left: 55px;
}
.navbar-nav.sm-collapsible ul ul ul ul .dropdown-menu > li > a,
.navbar-nav.sm-collapsible ul ul ul ul .dropdown-menu .dropdown-header {
	padding-left: 65px;
}
/* fix SmartMenus sub menus auto width (subMenusMinWidth and subMenusMaxWidth options) */
.navbar-nav .dropdown-menu > li > a {
	white-space: normal;
}
.navbar-nav ul.sm-nowrap > li > a {
	white-space: nowrap;
}
.navbar-nav.sm-collapsible ul.sm-nowrap > li > a {
	white-space: normal;
}
/* fix .navbar-right subs alignment */
.navbar-right ul.dropdown-menu {
	left: 0;
	right: auto;
}
 No newline at end of file
Original line number Original line Diff line number Diff line
/*!
 * SmartMenus jQuery Plugin Bootstrap Addon - v0.3.1 - November 1, 2016
 * http://www.smartmenus.org/
 *
 * Copyright Vasil Dinkov, Vadikom Web Ltd.
 * http://vadikom.com
 *
 * Licensed MIT
 */

(function(factory) {
	if (typeof define === 'function' && define.amd) {
		// AMD
		define(['jquery', 'jquery.smartmenus'], factory);
	} else if (typeof module === 'object' && typeof module.exports === 'object') {
		// CommonJS
		module.exports = factory(require('jquery'));
	} else {
		// Global jQuery
		factory(jQuery);
	}
} (function($) {

	$.extend($.SmartMenus.Bootstrap = {}, {
		keydownFix: false,
		init: function() {
			// init all navbars that don't have the "data-sm-skip" attribute set
			var $navbars = $('ul.navbar-nav:not([data-sm-skip])');
			$navbars.each(function() {
				var $this = $(this),
					obj = $this.data('smartmenus');
				// if this navbar is not initialized
				if (!obj) {
					$this.smartmenus({

							// these are some good default options that should work for all
							// you can, of course, tweak these as you like
							subMenusSubOffsetX: 2,
							subMenusSubOffsetY: -6,
							subIndicators: false,
							collapsibleShowFunction: null,
							collapsibleHideFunction: null,
							rightToLeftSubMenus: $this.hasClass('navbar-right'),
							bottomToTopSubMenus: $this.closest('.navbar').hasClass('navbar-fixed-bottom')
						})
						.bind({
							// set/unset proper Bootstrap classes for some menu elements
							'show.smapi': function(e, menu) {
								var $menu = $(menu),
									$scrollArrows = $menu.dataSM('scroll-arrows');
								if ($scrollArrows) {
									// they inherit border-color from body, so we can use its background-color too
									$scrollArrows.css('background-color', $(document.body).css('background-color'));
								}
								$menu.parent().addClass('open');
							},
							'hide.smapi': function(e, menu) {
								$(menu).parent().removeClass('open');
							}
						});

					function onInit() {
						// set Bootstrap's "active" class to SmartMenus "current" items (should someone decide to enable markCurrentItem: true)
						$this.find('a.current').parent().addClass('active');
						// remove any Bootstrap required attributes that might cause conflicting issues with the SmartMenus script
						$this.find('a.has-submenu').each(function() {
							var $this = $(this);
							if ($this.is('[data-toggle="dropdown"]')) {
								$this.dataSM('bs-data-toggle-dropdown', true).removeAttr('data-toggle');
							}
							if ($this.is('[role="button"]')) {
								$this.dataSM('bs-role-button', true).removeAttr('role');
							}
						});
					}

					onInit();

					function onBeforeDestroy() {
						$this.find('a.current').parent().removeClass('active');
						$this.find('a.has-submenu').each(function() {
							var $this = $(this);
							if ($this.dataSM('bs-data-toggle-dropdown')) {
								$this.attr('data-toggle', 'dropdown').removeDataSM('bs-data-toggle-dropdown');
							}
							if ($this.dataSM('bs-role-button')) {
								$this.attr('role', 'button').removeDataSM('bs-role-button');
							}
						});
					}

					obj = $this.data('smartmenus');

					// custom "isCollapsible" method for Bootstrap
					obj.isCollapsible = function() {
						return !/^(left|right)$/.test(this.$firstLink.parent().css('float'));
					};

					// custom "refresh" method for Bootstrap
					obj.refresh = function() {
						$.SmartMenus.prototype.refresh.call(this);
						onInit();
						// update collapsible detection
						detectCollapsible(true);
					};

					// custom "destroy" method for Bootstrap
					obj.destroy = function(refresh) {
						onBeforeDestroy();
						$.SmartMenus.prototype.destroy.call(this, refresh);
					};

					// keep Bootstrap's default behavior for parent items when the "data-sm-skip-collapsible-behavior" attribute is set to the ul.navbar-nav
					// i.e. use the whole item area just as a sub menu toggle and don't customize the carets
					if ($this.is('[data-sm-skip-collapsible-behavior]')) {
						$this.bind({
							// click the parent item to toggle the sub menus (and reset deeper levels and other branches on click)
							'click.smapi': function(e, item) {
								if (obj.isCollapsible()) {
									var $item = $(item),
										$sub = $item.parent().dataSM('sub');
									if ($sub && $sub.dataSM('shown-before') && $sub.is(':visible')) {
										obj.itemActivate($item);
										obj.menuHide($sub);
										return false;
									}
								}
							}
						});
					}

					// onresize detect when the navbar becomes collapsible and add it the "sm-collapsible" class
					var winW;
					function detectCollapsible(force) {
						var newW = obj.getViewportWidth();
						if (newW != winW || force) {
							var $carets = $this.find('.caret');
							if (obj.isCollapsible()) {
								$this.addClass('sm-collapsible');
								// set "navbar-toggle" class to carets (so they look like a button) if the "data-sm-skip-collapsible-behavior" attribute is not set to the ul.navbar-nav
								if (!$this.is('[data-sm-skip-collapsible-behavior]')) {
									$carets.addClass('navbar-toggle sub-arrow');
								}
							} else {
								$this.removeClass('sm-collapsible');
								if (!$this.is('[data-sm-skip-collapsible-behavior]')) {
									$carets.removeClass('navbar-toggle sub-arrow');
								}
							}
							winW = newW;
						}
					}
					detectCollapsible();
					$(window).bind('resize.smartmenus' + obj.rootId, detectCollapsible);
				}
			});
			// keydown fix for Bootstrap 3.3.5+ conflict
			if ($navbars.length && !$.SmartMenus.Bootstrap.keydownFix) {
				// unhook BS keydown handler for all dropdowns
				$(document).off('keydown.bs.dropdown.data-api', '.dropdown-menu');
				// restore BS keydown handler for dropdowns that are not inside SmartMenus navbars
				if ($.fn.dropdown && $.fn.dropdown.Constructor) {
					$(document).on('keydown.bs.dropdown.data-api', '.dropdown-menu:not([id^="sm-"])', $.fn.dropdown.Constructor.prototype.keydown);
				}
				$.SmartMenus.Bootstrap.keydownFix = true;
			}
		}
	});

	// init ondomready
	$($.SmartMenus.Bootstrap.init);

	return $;
}));
 No newline at end of file
Original line number Original line Diff line number Diff line
/*! SmartMenus jQuery Plugin Bootstrap Addon - v0.3.1 - November 1, 2016
 * http://www.smartmenus.org/
 * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery","jquery.smartmenus"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function(t){return t.extend(t.SmartMenus.Bootstrap={},{keydownFix:!1,init:function(){var e=t("ul.navbar-nav:not([data-sm-skip])");e.each(function(){function e(){o.find("a.current").parent().addClass("active"),o.find("a.has-submenu").each(function(){var e=t(this);e.is('[data-toggle="dropdown"]')&&e.dataSM("bs-data-toggle-dropdown",!0).removeAttr("data-toggle"),e.is('[role="button"]')&&e.dataSM("bs-role-button",!0).removeAttr("role")})}function s(){o.find("a.current").parent().removeClass("active"),o.find("a.has-submenu").each(function(){var e=t(this);e.dataSM("bs-data-toggle-dropdown")&&e.attr("data-toggle","dropdown").removeDataSM("bs-data-toggle-dropdown"),e.dataSM("bs-role-button")&&e.attr("role","button").removeDataSM("bs-role-button")})}function i(t){var e=a.getViewportWidth();if(e!=n||t){var s=o.find(".caret");a.isCollapsible()?(o.addClass("sm-collapsible"),o.is("[data-sm-skip-collapsible-behavior]")||s.addClass("navbar-toggle sub-arrow")):(o.removeClass("sm-collapsible"),o.is("[data-sm-skip-collapsible-behavior]")||s.removeClass("navbar-toggle sub-arrow")),n=e}}var o=t(this),a=o.data("smartmenus");if(!a){o.smartmenus({subMenusSubOffsetX:2,subMenusSubOffsetY:-6,subIndicators:!1,collapsibleShowFunction:null,collapsibleHideFunction:null,rightToLeftSubMenus:o.hasClass("navbar-right"),bottomToTopSubMenus:o.closest(".navbar").hasClass("navbar-fixed-bottom")}).bind({"show.smapi":function(e,s){var i=t(s),o=i.dataSM("scroll-arrows");o&&o.css("background-color",t(document.body).css("background-color")),i.parent().addClass("open")},"hide.smapi":function(e,s){t(s).parent().removeClass("open")}}),e(),a=o.data("smartmenus"),a.isCollapsible=function(){return!/^(left|right)$/.test(this.$firstLink.parent().css("float"))},a.refresh=function(){t.SmartMenus.prototype.refresh.call(this),e(),i(!0)},a.destroy=function(e){s(),t.SmartMenus.prototype.destroy.call(this,e)},o.is("[data-sm-skip-collapsible-behavior]")&&o.bind({"click.smapi":function(e,s){if(a.isCollapsible()){var i=t(s),o=i.parent().dataSM("sub");if(o&&o.dataSM("shown-before")&&o.is(":visible"))return a.itemActivate(i),a.menuHide(o),!1}}});var n;i(),t(window).bind("resize.smartmenus"+a.rootId,i)}}),e.length&&!t.SmartMenus.Bootstrap.keydownFix&&(t(document).off("keydown.bs.dropdown.data-api",".dropdown-menu"),t.fn.dropdown&&t.fn.dropdown.Constructor&&t(document).on("keydown.bs.dropdown.data-api",'.dropdown-menu:not([id^="sm-"])',t.fn.dropdown.Constructor.prototype.keydown),t.SmartMenus.Bootstrap.keydownFix=!0)}}),t(t.SmartMenus.Bootstrap.init),t});
 No newline at end of file
Original line number Original line Diff line number Diff line
/*!
 * SmartMenus jQuery Plugin Keyboard Addon - v0.3.1 - November 1, 2016
 * http://www.smartmenus.org/
 *
 * Copyright Vasil Dinkov, Vadikom Web Ltd.
 * http://vadikom.com
 *
 * Licensed MIT
 */

(function(factory) {
	if (typeof define === 'function' && define.amd) {
		// AMD
		define(['jquery', 'jquery.smartmenus'], factory);
	} else if (typeof module === 'object' && typeof module.exports === 'object') {
		// CommonJS
		module.exports = factory(require('jquery'));
	} else {
		// Global jQuery
		factory(jQuery);
	}
} (function($) {

	function getFirstItemLink($ul) {
		// make sure we also allow the link to be nested deeper inside the LI's (e.g. in a heading)
		return $ul.find('> li > a:not(.disabled), > li > :not(ul) a:not(.disabled)').eq(0);
	}
	function getLastItemLink($ul) {
		return $ul.find('> li > a:not(.disabled), > li > :not(ul) a:not(.disabled)').eq(-1);
	}
	function getNextItemLink($li, noLoop) {
		var $a = $li.nextAll('li').find('> a:not(.disabled), > :not(ul) a:not(.disabled)').eq(0);
		return noLoop || $a.length ? $a : getFirstItemLink($li.parent());
	}
	function getPreviousItemLink($li, noLoop) {
		// bug workaround: elements are returned in reverse order just in jQuery 1.8.x
		var $a = $li.prevAll('li').find('> a:not(.disabled), > :not(ul) a:not(.disabled)').eq(/^1\.8\./.test($.fn.jquery) ? 0 : -1);
		return noLoop || $a.length ? $a : getLastItemLink($li.parent());
	}

	// jQuery's .focus() is unreliable in some versions, so we're going to call the links' native JS focus method
	$.fn.focusSM = function() {
		if (this.length && this[0].focus) {
			this[0].focus();
		}
		return this;
	};

	$.extend($.SmartMenus.Keyboard = {}, {
		docKeydown: function(e) {
			var keyCode = e.keyCode;
			if (!/^(37|38|39|40)$/.test(keyCode)) {
				return;
			}
			var $root = $(this),
				obj = $root.data('smartmenus'),
				$target = $(e.target);
			// exit if this is an A inside a mega drop-down
			if (!obj || !$target.is('a') || !obj.handleItemEvents($target)) {
				return;
			}
			var $li = $target.closest('li'),
				$ul = $li.parent(),
				level = $ul.dataSM('level');
			// swap left & right keys
			if ($root.hasClass('sm-rtl')) {
				if (keyCode == 37) {
					keyCode = 39;
				} else if (keyCode == 39) {
					keyCode = 37;
				}
			}
			switch (keyCode) {
				case 37: // Left
					if (obj.isCollapsible()) {
						break;
					}
					if (level > 2 || level == 2 && $root.hasClass('sm-vertical')) {
						obj.activatedItems[level - 2].focusSM();
					// move to previous non-disabled parent item (make sure we cycle so it might be the last item)
					} else if (!$root.hasClass('sm-vertical')) {
						getPreviousItemLink((obj.activatedItems[0] || $target).closest('li')).focusSM();
					}
					break;
				case 38: // Up
					if (obj.isCollapsible()) {
						var $firstItem;
						// if this is the first item of a sub menu, move to the parent item
						if (level > 1 && ($firstItem = getFirstItemLink($ul)).length && $target[0] == $firstItem[0]) {
							obj.activatedItems[level - 2].focusSM();
						} else {
							getPreviousItemLink($li).focusSM();
						}
					} else {
						if (level == 1 && !$root.hasClass('sm-vertical') && obj.opts.bottomToTopSubMenus) {
							if (!obj.activatedItems[0] && $target.dataSM('sub')) {
								if (obj.opts.showOnClick) {
									obj.clickActivated = true;
								}
								obj.itemActivate($target);
								if ($target.dataSM('sub').is(':visible')) {
									obj.focusActivated = true;
								}
							}
							if (obj.activatedItems[0] && obj.activatedItems[0].dataSM('sub') && obj.activatedItems[0].dataSM('sub').is(':visible') && !obj.activatedItems[0].dataSM('sub').hasClass('mega-menu')) {
								getLastItemLink(obj.activatedItems[0].dataSM('sub')).focusSM();
							}
						} else if (level > 1 || $root.hasClass('sm-vertical')) {
							getPreviousItemLink($li).focusSM();
						}
					}
					break;
				case 39: // Right
					if (obj.isCollapsible()) {
						break;
					}
					if (level == 1 && $root.hasClass('sm-vertical')) {
						if (!obj.activatedItems[0] && $target.dataSM('sub')) {
							if (obj.opts.showOnClick) {
								obj.clickActivated = true;
							}
							obj.itemActivate($target);
							if ($target.dataSM('sub').is(':visible')) {
								obj.focusActivated = true;
							}
						}
						if (obj.activatedItems[0] && obj.activatedItems[0].dataSM('sub') && obj.activatedItems[0].dataSM('sub').is(':visible') && !obj.activatedItems[0].dataSM('sub').hasClass('mega-menu')) {
							getFirstItemLink(obj.activatedItems[0].dataSM('sub')).focusSM();
						}
					// move to next non-disabled parent item (make sure we cycle so it might be the last item)
					} else if ((level == 1 || obj.activatedItems[level - 1] && (!obj.activatedItems[level - 1].dataSM('sub') || !obj.activatedItems[level - 1].dataSM('sub').is(':visible') || obj.activatedItems[level - 1].dataSM('sub').hasClass('mega-menu'))) && !$root.hasClass('sm-vertical')) {
						getNextItemLink((obj.activatedItems[0] || $target).closest('li')).focusSM();
					} else if (obj.activatedItems[level - 1] && obj.activatedItems[level - 1].dataSM('sub') && obj.activatedItems[level - 1].dataSM('sub').is(':visible') && !obj.activatedItems[level - 1].dataSM('sub').hasClass('mega-menu')) {
						getFirstItemLink(obj.activatedItems[level - 1].dataSM('sub')).focusSM();
					}
					break;
				case 40: // Down
					if (obj.isCollapsible()) {
						var $firstSubItem,
							$lastItem;
						// move to sub menu if appropriate
						if (obj.activatedItems[level - 1] && obj.activatedItems[level - 1].dataSM('sub') && obj.activatedItems[level - 1].dataSM('sub').is(':visible') && !obj.activatedItems[level - 1].dataSM('sub').hasClass('mega-menu') && ($firstSubItem = getFirstItemLink(obj.activatedItems[level - 1].dataSM('sub'))).length) {
							$firstSubItem.focusSM();
						// if this is the last item of a sub menu, move to the next parent item
						} else if (level > 1 && ($lastItem = getLastItemLink($ul)).length && $target[0] == $lastItem[0]) {
							var $parentItem = obj.activatedItems[level - 2].closest('li'),
								$nextParentItem = null;
							while ($parentItem.is('li') && !($nextParentItem = getNextItemLink($parentItem, true)).length) {
								$parentItem = $parentItem.parent().parent();
							}
							if ($nextParentItem.length) {
								$nextParentItem.focusSM();
							} else {
								getFirstItemLink($root).focusSM();
							}
						} else {
							getNextItemLink($li).focusSM();
						}
					} else {
						if (level == 1 && !$root.hasClass('sm-vertical') && !obj.opts.bottomToTopSubMenus) {
							if (!obj.activatedItems[0] && $target.dataSM('sub')) {
								if (obj.opts.showOnClick) {
									obj.clickActivated = true;
								}
								obj.itemActivate($target);
								if ($target.dataSM('sub').is(':visible')) {
									obj.focusActivated = true;
								}
							}
							if (obj.activatedItems[0] && obj.activatedItems[0].dataSM('sub') && obj.activatedItems[0].dataSM('sub').is(':visible') && !obj.activatedItems[0].dataSM('sub').hasClass('mega-menu')) {
								getFirstItemLink(obj.activatedItems[0].dataSM('sub')).focusSM();
							}
						} else if (level > 1 || $root.hasClass('sm-vertical')) {
							getNextItemLink($li).focusSM();
						}
					}
					break;
			}
			e.stopPropagation();
			e.preventDefault();
		}
	});

	// hook it
	$(document).delegate('ul.sm, ul.navbar-nav:not([data-sm-skip])', 'keydown.smartmenus', $.SmartMenus.Keyboard.docKeydown);

	$.extend($.SmartMenus.prototype, {
		keyboardSetHotkey: function(keyCode, modifiers) {
			var self = this;
			$(document).bind('keydown.smartmenus' + this.rootId, function(e) {
				if (keyCode == e.keyCode) {
					var procede = true;
					if (modifiers) {
						if (typeof modifiers == 'string') {
							modifiers = [modifiers];
						}
						$.each(['ctrlKey', 'shiftKey', 'altKey', 'metaKey'], function(index, value) {
							if ($.inArray(value, modifiers) >= 0 && !e[value] || $.inArray(value, modifiers) < 0 && e[value]) {
								procede = false;
								return false;
							}
						});
					}
					if (procede) {
						getFirstItemLink(self.$root).focusSM();
						e.stopPropagation();
						e.preventDefault();
					}
				}
			});
		}
	});

	return $;
}));
 No newline at end of file
Original line number Original line Diff line number Diff line
/*! SmartMenus jQuery Plugin Keyboard Addon - v0.3.1 - November 1, 2016
 * http://www.smartmenus.org/
 * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery","jquery.smartmenus"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function(t){function e(t){return t.find("> li > a:not(.disabled), > li > :not(ul) a:not(.disabled)").eq(0)}function s(t){return t.find("> li > a:not(.disabled), > li > :not(ul) a:not(.disabled)").eq(-1)}function i(t,s){var i=t.nextAll("li").find("> a:not(.disabled), > :not(ul) a:not(.disabled)").eq(0);return s||i.length?i:e(t.parent())}function o(e,i){var o=e.prevAll("li").find("> a:not(.disabled), > :not(ul) a:not(.disabled)").eq(/^1\.8\./.test(t.fn.jquery)?0:-1);return i||o.length?o:s(e.parent())}return t.fn.focusSM=function(){return this.length&&this[0].focus&&this[0].focus(),this},t.extend(t.SmartMenus.Keyboard={},{docKeydown:function(a){var n=a.keyCode;if(/^(37|38|39|40)$/.test(n)){var r=t(this),u=r.data("smartmenus"),h=t(a.target);if(u&&h.is("a")&&u.handleItemEvents(h)){var l=h.closest("li"),d=l.parent(),c=d.dataSM("level");switch(r.hasClass("sm-rtl")&&(37==n?n=39:39==n&&(n=37)),n){case 37:if(u.isCollapsible())break;c>2||2==c&&r.hasClass("sm-vertical")?u.activatedItems[c-2].focusSM():r.hasClass("sm-vertical")||o((u.activatedItems[0]||h).closest("li")).focusSM();break;case 38:if(u.isCollapsible()){var m;c>1&&(m=e(d)).length&&h[0]==m[0]?u.activatedItems[c-2].focusSM():o(l).focusSM()}else 1==c&&!r.hasClass("sm-vertical")&&u.opts.bottomToTopSubMenus?(!u.activatedItems[0]&&h.dataSM("sub")&&(u.opts.showOnClick&&(u.clickActivated=!0),u.itemActivate(h),h.dataSM("sub").is(":visible")&&(u.focusActivated=!0)),u.activatedItems[0]&&u.activatedItems[0].dataSM("sub")&&u.activatedItems[0].dataSM("sub").is(":visible")&&!u.activatedItems[0].dataSM("sub").hasClass("mega-menu")&&s(u.activatedItems[0].dataSM("sub")).focusSM()):(c>1||r.hasClass("sm-vertical"))&&o(l).focusSM();break;case 39:if(u.isCollapsible())break;1==c&&r.hasClass("sm-vertical")?(!u.activatedItems[0]&&h.dataSM("sub")&&(u.opts.showOnClick&&(u.clickActivated=!0),u.itemActivate(h),h.dataSM("sub").is(":visible")&&(u.focusActivated=!0)),u.activatedItems[0]&&u.activatedItems[0].dataSM("sub")&&u.activatedItems[0].dataSM("sub").is(":visible")&&!u.activatedItems[0].dataSM("sub").hasClass("mega-menu")&&e(u.activatedItems[0].dataSM("sub")).focusSM()):1!=c&&(!u.activatedItems[c-1]||u.activatedItems[c-1].dataSM("sub")&&u.activatedItems[c-1].dataSM("sub").is(":visible")&&!u.activatedItems[c-1].dataSM("sub").hasClass("mega-menu"))||r.hasClass("sm-vertical")?u.activatedItems[c-1]&&u.activatedItems[c-1].dataSM("sub")&&u.activatedItems[c-1].dataSM("sub").is(":visible")&&!u.activatedItems[c-1].dataSM("sub").hasClass("mega-menu")&&e(u.activatedItems[c-1].dataSM("sub")).focusSM():i((u.activatedItems[0]||h).closest("li")).focusSM();break;case 40:if(u.isCollapsible()){var p,f;if(u.activatedItems[c-1]&&u.activatedItems[c-1].dataSM("sub")&&u.activatedItems[c-1].dataSM("sub").is(":visible")&&!u.activatedItems[c-1].dataSM("sub").hasClass("mega-menu")&&(p=e(u.activatedItems[c-1].dataSM("sub"))).length)p.focusSM();else if(c>1&&(f=s(d)).length&&h[0]==f[0]){for(var v=u.activatedItems[c-2].closest("li"),b=null;v.is("li")&&!(b=i(v,!0)).length;)v=v.parent().parent();b.length?b.focusSM():e(r).focusSM()}else i(l).focusSM()}else 1!=c||r.hasClass("sm-vertical")||u.opts.bottomToTopSubMenus?(c>1||r.hasClass("sm-vertical"))&&i(l).focusSM():(!u.activatedItems[0]&&h.dataSM("sub")&&(u.opts.showOnClick&&(u.clickActivated=!0),u.itemActivate(h),h.dataSM("sub").is(":visible")&&(u.focusActivated=!0)),u.activatedItems[0]&&u.activatedItems[0].dataSM("sub")&&u.activatedItems[0].dataSM("sub").is(":visible")&&!u.activatedItems[0].dataSM("sub").hasClass("mega-menu")&&e(u.activatedItems[0].dataSM("sub")).focusSM())}a.stopPropagation(),a.preventDefault()}}}}),t(document).delegate("ul.sm, ul.navbar-nav:not([data-sm-skip])","keydown.smartmenus",t.SmartMenus.Keyboard.docKeydown),t.extend(t.SmartMenus.prototype,{keyboardSetHotkey:function(s,i){var o=this;t(document).bind("keydown.smartmenus"+this.rootId,function(a){if(s==a.keyCode){var n=!0;i&&("string"==typeof i&&(i=[i]),t.each(["ctrlKey","shiftKey","altKey","metaKey"],function(e,s){return t.inArray(s,i)>=0&&!a[s]||0>t.inArray(s,i)&&a[s]?(n=!1,!1):void 0})),n&&(e(o.$root).focusSM(),a.stopPropagation(),a.preventDefault())}})}}),t});
 No newline at end of file

doc/customdoxygen.css

0 → 100644
+485 −0
Original line number Original line Diff line number Diff line
h1, .h1, h2, .h2, h3, .h3{
    font-weight: 200 !important;
}

.sm-dox a span.sub-arrow {
    position: absolute;
    top: 50%;
    margin-top: -14px;
    left: auto;
    right: 3px;
    width: 28px;
    height: 28px;
    overflow: hidden;
    font: bold 12px / 28px monospace !important;
    text-align: center;
    text-shadow: none;
    background: rgba(255, 255, 255, 0.5);
    -moz-border-radius: 5px;
    -webkit-border-radius: 5px;
    border-radius: 5px
}

/* Handing of arrow-carets in the smart menus */
.sm-dox a.highlighted span.sub-arrow:before {
    display: block;
    content: '-'
}

.sm-dox a span.sub-arrow {
    top: 50%;
    margin-top: -2px;
    right: 12px;
    width: 0;
    height: 0;
    border-width: 4px;
    border-style: solid dashed dashed dashed;
    border-color: #283a5d transparent transparent transparent;
    background: transparent;
    -moz-border-radius: 0;
    -webkit-border-radius: 0;
    border-radius: 0
}

.sm-dox a:hover span.sub-arrow {
    border-color: red transparent transparent transparent
}


.sm-dox.sm-rtl a.has-submenu {
    padding-right: 12px;
    padding-left: 24px
}

.sm-dox.sm-rtl a span.sub-arrow {
    right: auto;
    left: 12px
}

.sm-dox.sm-rtl.sm-vertical a.has-submenu {
    padding: 10px 20px
}

.sm-dox.sm-rtl.sm-vertical a span.sub-arrow {
    right: auto;
    left: 8px;
    border-style: dashed solid dashed dashed;
    border-color: transparent #555 transparent transparent
}

.sm-dox.sm-rtl ul a.has-submenu {
    padding: 10px 20px !important
}

.sm-dox.sm-rtl ul a span.sub-arrow {
    right: auto;
    left: 8px;
    border-style: dashed solid dashed dashed;
    border-color: transparent #555 transparent transparent
}

.sm-dox.sm-vertical a.disabled {
}

.sm-dox.sm-vertical a span.sub-arrow {
    right: 8px;
    top: 50%;
    margin-top: -5px;
    border-width: 5px;
    border-style: dashed dashed dashed solid;
    border-color: transparent transparent transparent #555
}
.sm-dox ul a span.sub-arrow {
    right: 8px;
    top: 50%;
    margin-top: -5px;
    border-width: 5px;
    border-color: transparent transparent transparent #555;
    border-style: dashed dashed dashed solid
}

#navrow1, #navrow2, #navrow3, #navrow4, #navrow5{
    border-bottom: 1px solid #EEEEEE;
}

.adjust-right {
margin-left: 30px !important;
font-size: 1.15em !important;
}
.navbar{
 border: 0px solid #222 !important;
}
table{
    white-space:pre-wrap !important;
}
/*
 ===========================
 */


/* Sticky footer styles
-------------------------------------------------- */
html,
body {
    height: 100%;
    /* The html and body elements cannot have any padding or margin. */
}

/* Wrapper for page content to push down footer */
#wrap {
    min-height: 100%;
    height: auto;
    /* Negative indent footer by its height */
    margin: 0 auto -60px;
    /* Pad bottom by footer height */
    padding: 0 0 60px;
}

/* Set the fixed height of the footer here */
#footer {
    font-size: 0.9em;
    padding: 8px 0px;
    background-color: #f5f5f5;
}

.footer-row {
    line-height: 44px;
}

#footer > .container {
    padding-left: 15px;
    padding-right: 15px;
}

.footer-follow-icon {
    margin-left: 3px;
    text-decoration: none !important;
}

.footer-follow-icon img {
    width: 20px;
}

.footer-link {
    padding-top: 5px;
    display: inline-block;
    color: #999999;
    text-decoration: none;
}

.footer-copyright {
    text-align: center;
}


@media (min-width: 992px) {
    .footer-row {
        text-align: left;
    }

    .footer-icons {
        text-align: right;
    }
}
@media (max-width: 991px) {
    .footer-row {
        text-align: center;
    }

    .footer-icons {
        text-align: center;
    }
}

/* DOXYGEN Code Styles
----------------------------------- */


a.qindex {
    font-weight: bold;
}

a.qindexHL {
    font-weight: bold;
    background-color: #9CAFD4;
    color: #ffffff;
    border: 1px double #869DCA;
}

.contents a.qindexHL:visited {
    color: #ffffff;
}

a.code, a.code:visited, a.line, a.line:visited {
    color: #4665A2;
}

a.codeRef, a.codeRef:visited, a.lineRef, a.lineRef:visited {
    color: #4665A2;
}

/* @end */

dl.el {
    margin-left: -1cm;
}

pre.fragment {
    border: 1px solid #C4CFE5;
    background-color: #FBFCFD;
    padding: 4px 6px;
    margin: 4px 8px 4px 2px;
    overflow: auto;
    word-wrap: break-word;
    font-size:  9pt;
    line-height: 125%;
    font-family: monospace, fixed;
    font-size: 105%;
}

div.fragment {
    padding: 4px 6px;
    margin: 4px 8px 4px 2px;
    border: 1px solid #C4CFE5;
}

div.line {
    font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
    font-size: 12px;
    min-height: 13px;
    line-height: 1.0;
    text-wrap: unrestricted;
    white-space: -moz-pre-wrap; /* Moz */
    white-space: -pre-wrap;     /* Opera 4-6 */
    white-space: -o-pre-wrap;   /* Opera 7 */
    white-space: pre-wrap;      /* CSS3  */
    word-wrap: normal;      /* IE 5.5+ */
    text-indent: -53px;
    padding-left: 53px;
    padding-bottom: 0px;
    margin: 0px;
    -webkit-transition-property: background-color, box-shadow;
    -webkit-transition-duration: 0.5s;
    -moz-transition-property: background-color, box-shadow;
    -moz-transition-duration: 0.5s;
    -ms-transition-property: background-color, box-shadow;
    -ms-transition-duration: 0.5s;
    -o-transition-property: background-color, box-shadow;
    -o-transition-duration: 0.5s;
    transition-property: background-color, box-shadow;
    transition-duration: 0.5s;
}
div.line:hover{
    background-color: #FBFF00;
}

div.line.glow {
    background-color: cyan;
    box-shadow: 0 0 10px cyan;
}


span.lineno {
    padding-right: 4px;
    text-align: right;
    color:rgba(0,0,0,0.3);
    border-right: 1px solid #EEE;
    border-left: 1px solid #EEE;
    background-color: #FFF;
    white-space: pre;
    font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace ;
}
span.lineno a {
    background-color: #FAFAFA;
    cursor:pointer;
}

span.lineno a:hover {
    background-color: #EFE200;
    color: #1e1e1e;
}

div.groupHeader {
    margin-left: 16px;
    margin-top: 12px;
    font-weight: bold;
}

div.groupText {
    margin-left: 16px;
    font-style: italic;
}

/* @group Code Colorization */

span.keyword {
    color: #008000
}

span.keywordtype {
    color: #604020
}

span.keywordflow {
    color: #e08000
}

span.comment {
    color: #800000
}

span.preprocessor {
    color: #806020
}

span.stringliteral {
    color: #002080
}

span.charliteral {
    color: #008080
}

span.vhdldigit {
    color: #ff00ff
}

span.vhdlchar {
    color: #000000
}

span.vhdlkeyword {
    color: #700070
}

span.vhdllogic {
    color: #ff0000
}

blockquote {
    background-color: #F7F8FB;
    border-left: 2px solid #9CAFD4;
    margin: 0 24px 0 4px;
    padding: 0 12px 0 16px;
}

/*---------------- Search Box */

#search-box {
  margin: 10px 0px;
}
#search-box .close {
  display: none;
  position: absolute;
  right: 0px;
  padding: 6px 12px;
  z-index: 5;
}

/*---------------- Search results window */

#search-results-window {
  display: none;
}

iframe#MSearchResults {
  width: 100%;
  height: 15em;
}

.SRChildren {
  padding-left: 3ex; padding-bottom: .5em
}
.SRPage .SRChildren {
  display: none;
}
a.SRScope {
  display: block;
}
a.SRSymbol:focus, a.SRSymbol:active,
a.SRScope:focus, a.SRScope:active {
  text-decoration: underline;
}
span.SRScope {
  padding-left: 4px;
}
.SRResult {
  display: none;
}

/* class and file list */
.directory .icona,
.directory .arrow {
  height: auto;
}
.directory .icona .icon {
  height: 16px;
}
.directory .icondoc {
  background-position: 0px 0px;
  height: 20px;
}
.directory .iconfopen {
  background-position: 0px 0px;
}
.directory td.entry {
  padding: 7px 8px 6px 8px;
}

.table > tbody > tr > td.memSeparator {
  line-height: 0;
  .table-hover;

}

.memItemLeft, .memTemplItemLeft {
  white-space: normal;
}

/* enumerations */
.panel-body thead > tr {
  background-color: #e0e0e0;
}

/* todo lists */
.todoname,
.todoname a {
  font-weight: bold;
}

/* Class title */
.summary {
  margin-top: 25px;
}
.page-header {
  margin: 20px 0px !important;
}
.page-header .title {
  display: inline-block;
}
.page-header .pull-right {
  margin-top: 0.3em;
  margin-left: 0.5em;
}
.page-header .label {
  font-size: 50%;
}

@media print
{
  #top { display: none; }
  #side-nav { display: none; }
  #nav-path { display: none; }
  body { overflow:visible; }
  h1, h2, h3, h4, h5, h6 { page-break-after: avoid; }
  .summary { display: none; }
  .memitem { page-break-inside: avoid; }
  #doc-content
  {
    margin-left:0 !important;
    height:auto !important;
    width:auto !important;
    overflow:inherit;
    display:inline;
  }
}

doc/doxy-boot.js

0 → 100644
+278 −0
Original line number Original line Diff line number Diff line
$( document ).ready(function() {
    $("div.headertitle").addClass("page-header");
    $("div.title").addClass("h1");

    $('li > a[href="index.html"] > span').before("<i class='fa fa-cog'></i> ");
    $('li > a[href="modules.html"] > span').before("<i class='fa fa-square'></i> ");
    $('li > a[href="namespaces.html"] > span').before("<i class='fa fa-bars'></i> ");
    $('li > a[href="annotated.html"] > span').before("<i class='fa fa-list-ul'></i> ");
    $('li > a[href="classes.html"] > span').before("<i class='fa fa-book'></i> ");
    $('li > a[href="inherits.html"] > span').before("<i class='fa fa-sitemap'></i> ");
    $('li > a[href="functions.html"] > span').before("<i class='fa fa-list'></i> ");
    $('li > a[href="functions_func.html"] > span').before("<i class='fa fa-list'></i> ");
    $('li > a[href="functions_vars.html"] > span').before("<i class='fa fa-list'></i> ");
    $('li > a[href="functions_enum.html"] > span').before("<i class='fa fa-list'></i> ");
    $('li > a[href="functions_eval.html"] > span').before("<i class='fa fa-list'></i> ");
    $('img[src="ftv2ns.png"]').replaceWith('<span class="label label-danger">N</span> ');
    $('img[src="ftv2cl.png"]').replaceWith('<span class="label label-danger">C</span> ');

    $("ul.tablist").addClass("nav nav-pills nav-justified");
    $("ul.tablist").css("margin-top", "0.5em");
    $("ul.tablist").css("margin-bottom", "0.5em");
    $("li.current").addClass("active");
    $("iframe").attr("scrolling", "yes");

    $("#nav-path > ul").addClass("breadcrumb");

    $("table.params").addClass("table");
    $("div.ingroups").wrapInner("<span class='text-nowrap'></span>");
    $("div.levels").css("margin", "0.5em");
    $("div.levels > span").addClass("btn btn-default btn-xs");
    $("div.levels > span").css("margin-right", "0.25em");

    $("table.directory").addClass("table table-striped");
    $("div.summary > a").addClass("btn btn-default btn-xs");
    $("table.fieldtable").addClass("table");
    $(".fragment").addClass("well");
    $(".memitem").addClass("panel panel-default");
    $(".memproto").addClass("panel-heading");
    $(".memdoc").addClass("panel-body");
    $("span.mlabel").addClass("label label-info");

    $("table.memberdecls").addClass("table");
    $("[class^=memitem]").addClass("active");

    $("div.ah").addClass("btn btn-default");
    $("span.mlabels").addClass("pull-right");
    $("table.mlabels").css("width", "100%")
    $("td.mlabels-right").addClass("pull-right");

    $("div.ttc").addClass("panel panel-primary");
    $("div.ttname").addClass("panel-heading");
    $("div.ttname a").css("color", 'white');
    $("div.ttdef,div.ttdoc,div.ttdeci").addClass("panel-body");

    $('div.fragment.well div.line:first').css('margin-top', '2px');
    $('div.fragment.well div.line:last').css('margin-bottom', '2px');

	$('table.doxtable').removeClass('doxtable').addClass('table table-striped table-bordered').each(function(){
		$(this).prepend('<thead></thead>');
		$(this).find('tbody > tr:first').prependTo($(this).find('thead'));

		$(this).find('td > span.success').parent().addClass('success');
		$(this).find('td > span.warning').parent().addClass('warning');
		$(this).find('td > span.danger').parent().addClass('danger');
	});



    if($('div.fragment.well div.ttc').length > 0)
    {
        $('div.fragment.well div.line:first').parent().removeClass('fragment well');
    }

    $('table.memberdecls').find('.memItemRight').each(function(){
        $(this).contents().appendTo($(this).siblings('.memItemLeft'));
        $(this).siblings('.memItemLeft').attr('align', 'left');
    });

    $('table.memberdecls').find('.memTemplItemRight').each(function(){
        $(this).contents().appendTo($(this).siblings('.memTemplItemLeft'));
        $(this).siblings('.memTemplItemLeft').attr('align', 'left');
    });

	function getOriginalWidthOfImg(img_element) {
		var t = new Image();
		t.src = (img_element.getAttribute ? img_element.getAttribute("src") : false) || img_element.src;
		return t.width;
	}

	$('div.dyncontent').find('img').each(function(){
		if(getOriginalWidthOfImg($(this)[0]) > $('#content>div.container').width())
			$(this).css('width', '100%');
	});

    var nav_container = $('#main-nav').detach();
    nav_container.addClass('nav navbar-nav navbar-right');
    $('nav > .container').append(nav_container);
    $('#main-nav > ul').addClass('nav navbar-nav navbar-right');
    $('#main-nav * li > ul').addClass('dropdown-menu');



  /* responsive search box */
  //$('#MSearchBox').parent().remove();

    /*
  var nav_container = $('<div class="row"></div>');
  $('#navrow1').parent().prepend(nav_container);

  var left_nav = $('<div class="col-md-9"></div>');
  for (i = 0; i < 6; i++) {
    var navrow = $('#navrow' + i + ' > ul.tablist').detach();
    left_nav.append(navrow);
    $('#navrow' + i).remove();
  }
  var right_nav = $('<div class="col-md-3"></div>').append('\
    <div id="search-box" class="input-group">\
      <div class="input-group-btn">\
        <button aria-expanded="false" type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">\
          <span class="glyphicon glyphicon-search"></span> <span class="caret"></span>\
        </button>\
        <ul class="dropdown-menu">\
        </ul>\
      </div>\
      <button id="search-close" type="button" class="close" aria-label="Close"><span aria-hidden="true">&times;</span></button>\
      <input id="search-field" class="form-control" accesskey="S" onkeydown="searchBox.OnSearchFieldChange(event);" placeholder="Search ..." type="text">\
    </div>');
  $(nav_container).append(left_nav);
  $(nav_container).append(right_nav);


  $('#MSearchSelectWindow .SelectionMark').remove();
  var search_selectors = $('#MSearchSelectWindow .SelectItem');
  for (var i = 0; i < search_selectors.length; i += 1) {
    var element_a = $('<a href="#"></a>').text($(search_selectors[i]).text());

    element_a.click(function(){
      $('#search-box .dropdown-menu li').removeClass('active');
      $(this).parent().addClass('active');
      searchBox.OnSelectItem($('#search-box li a').index(this));
      searchBox.Search();
      return false;
    });

    var element = $('<li></li>').append(element_a);
    $('#search-box .dropdown-menu').append(element);
  }
  $('#MSearchSelectWindow').remove();

  $('#search-box .close').click(function (){
    searchBox.CloseResultsWindow();
  });

  $('body').append('<div id="MSearchClose"></div>');
  $('body').append('<div id="MSearchBox"></div>');
  $('body').append('<div id="MSearchSelectWindow"></div>');

  searchBox.searchLabel = '';
  searchBox.DOMSearchField = function() {
    return document.getElementById("search-field");
  }
  searchBox.DOMSearchClose = function(){
    return document.getElementById("search-close");
  }
  */
  /* search results */

  var results_iframe = $('#MSearchResults').detach();
  $('#MSearchResultsWindow')
    .attr('id', 'search-results-window')
    .addClass('panel panel-default')
    .append(
      '<div class="panel-heading">\
        <h3 class="panel-title">Search Results</h3>\
      </div>\
      <div class="panel-body"></div>'
    );
  $('#search-results-window .panel-body').append(results_iframe);

  //searchBox.DOMPopupSearchResultsWindow = function() {
  //  return document.getElementById("search-results-window");
  //}

  function update_search_results_window() {
    $('#search-results-window').removeClass('panel-default panel-success panel-warning panel-danger')
    var status = $('#MSearchResults').contents().find('.SRStatus:visible');
    if (status.length > 0) {
      switch(status.attr('id')) {
        case 'Loading':
        case 'Searching':
          $('#search-results-window').addClass('panel-warning');
          break;
        case 'NoMatches':
          $('#search-results-window').addClass('panel-danger');
          break;
        default:
          $('#search-results-window').addClass('panel-default');
      }
    } else {
      $('#search-results-window').addClass('panel-success');
    }
  }
  $('#MSearchResults').load(function() {
    $('#MSearchResults').contents().find('link[href="search.css"]').attr('href','../doxygen.css');
    $('#MSearchResults').contents().find('head').append(
      '<link href="../customdoxygen.css" rel="stylesheet" type="text/css">');

    update_search_results_window();

    // detect status changes (only for search with external search backend)
    var observer = new MutationObserver(function(mutations) {
      update_search_results_window();
    });
    var config = { attributes: true};

    var targets = $('#MSearchResults').contents().find('.SRStatus');
    for (i = 0; i < targets.length; i++) {
      observer.observe(targets[i], config);
    }
  });

  /* enumerations */
  $('table.fieldtable').removeClass('fieldtable').addClass('table table-striped table-bordered').each(function(){
    $(this).prepend('<thead></thead>');
    $(this).find('tbody > tr:first').prependTo($(this).find('thead'));

    $(this).find('td > span.success').parent().addClass('success');
    $(this).find('td > span.warning').parent().addClass('warning');
    $(this).find('td > span.danger').parent().addClass('danger');
  });

  /* todo list */
  var todoelements = $('.contents > .textblock > dl.reflist > dt, .contents > .textblock > dl.reflist > dd');
  for (var i = 0; i < todoelements.length; i += 2) {
    $('.contents > .textblock').append(
      '<div class="panel panel-default active">'
        + "<div class=\"panel-heading todoname\">" + $(todoelements[i]).html() + "</div>"
        + "<div class=\"panel-body\">" + $(todoelements[i+1]).html() + "</div>"
      + '</div>');
  }
  $('.contents > .textblock > dl').remove();


	$(".memitem").removeClass('memitem');
    $(".memproto").removeClass('memproto');
    $(".memdoc").removeClass('memdoc');
	$("span.mlabel").removeClass('mlabel');
	$("table.memberdecls").removeClass('memberdecls');
    $("[class^=memitem]").removeClass('memitem');
    $("span.mlabels").removeClass('mlabels');
    $("table.mlabels").removeClass('mlabels');
    $("td.mlabels-right").removeClass('mlabels-right');
	$(".navpath").removeClass('navpath');
	$("li.navelem").removeClass('navelem');
	$("a.el").removeClass('el');
	$("div.ah").removeClass('ah');
	$("div.header").removeClass("header");

	$('.mdescLeft').each(function(){
		if($(this).html()=="&nbsp;") {
			$(this).siblings('.mdescRight').attr('colspan', 2);
			$(this).remove();
		}
	});
  $('td.memItemLeft').each(function(){
    if($(this).siblings('.memItemRight').html()=="") {
      $(this).attr('colspan', 2);
      $(this).siblings('.memItemRight').remove();
    }
  });
	$('td.memTemplItemLeft').each(function(){
		if($(this).siblings('.memTemplItemRight').html()=="") {
			$(this).attr('colspan', 2);
			$(this).siblings('.memTemplItemRight').remove();
		}
	});
  //searchBox.CloseResultsWindow();
});

doc/footer.html

0 → 100644
+27 −0
Original line number Original line Diff line number Diff line
<!-- HTML footer for doxygen 1.8.8-->
<!-- start footer part -->
<!--BEGIN GENERATE_TREEVIEW-->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    $navpath
    <li class="footer">$generatedby
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="$relpath^doxygen.png" alt="doxygen"/></a> $doxygenversion </li>
  </ul>
</div>
<!--END GENERATE_TREEVIEW-->
</div>
</div>
</div>
</div>
</div>
<!--BEGIN !GENERATE_TREEVIEW-->
<hr class="footer"/><address class="footer"><small>
$generatedby &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="$relpath^doxygen.png" alt="doxygen"/>
</a> $doxygenversion
</small></address>
<!--END !GENERATE_TREEVIEW-->
</body>
        <script type="text/javascript" src="$relpath^doxy-boot.js"></script>
</html>

doc/header.html

0 → 100644
+47 −0
Original line number Original line Diff line number Diff line
<!-- HTML header for doxygen 1.8.8-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <!-- For Mobile Devices -->
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
        <meta name="generator" content="Doxygen $doxygenversion"/>
        
        <script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script>

        <!--BEGIN PROJECT_NAME--><title>$projectname: $title</title><!--END PROJECT_NAME-->
        <!--BEGIN !PROJECT_NAME--><title>$title</title><!--END !PROJECT_NAME-->
        <!--<link href="$relpath^tabs.css" rel="stylesheet" type="text/css"/>-->
        <script type="text/javascript" src="$relpath^dynsections.js"></script>
        $treeview
        $search
        $mathjax
        <link href="$relpath^$stylesheet" rel="stylesheet" type="text/css" />
        $extrastylesheet
        <link href='https://fonts.googleapis.com/css?family=Roboto+Slab' rel='stylesheet' type='text/css'>
        <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
        <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
        <link href="$relpath^jquery.smartmenus.bootstrap.css" rel="stylesheet">

        <script type="text/javascript" src="$relpath^jquery.smartmenus.js"></script>
        <!-- SmartMenus jQuery Bootstrap Addon -->
        <script type="text/javascript" src="$relpath^jquery.smartmenus.bootstrap.js"></script>
        <!-- SmartMenus jQuery plugin -->
    </head>
    <body>
        <nav class="navbar navbar-default" role="navigation">
            <div class="container">
                <div class="navbar-header">
                    <a class="navbar-brand">$projectname $projectnumber</a>
                </div>
            </div>
        </nav>
        <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
            <div class="content" id="content">
                <div class="container">
                    <div class="row">
                        <div class="col-sm-12 panel " style="padding-bottom: 15px;">
                            <div style="margin-bottom: 15px;">
<!-- end header part -->
+1223 −0

File added.

Preview size limit exceeded, changes collapsed.

doc/new_footer.html

0 → 100644
+21 −0
Original line number Original line Diff line number Diff line
<!-- HTML footer for doxygen 1.8.13-->
<!-- start footer part -->
<!--BEGIN GENERATE_TREEVIEW-->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    $navpath
    <li class="footer">$generatedby
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="$relpath^doxygen.png" alt="doxygen"/></a> $doxygenversion </li>
  </ul>
</div>
<!--END GENERATE_TREEVIEW-->
<!--BEGIN !GENERATE_TREEVIEW-->
<hr class="footer"/><address class="footer"><small>
$generatedby &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="$relpath^doxygen.png" alt="doxygen"/>
</a> $doxygenversion
</small></address>
<!--END !GENERATE_TREEVIEW-->
</body>
</html>

doc/new_header.html

0 → 100644
+56 −0
Original line number Original line Diff line number Diff line
<!-- HTML header for doxygen 1.8.13-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen $doxygenversion"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<!--BEGIN PROJECT_NAME--><title>$projectname: $title</title><!--END PROJECT_NAME-->
<!--BEGIN !PROJECT_NAME--><title>$title</title><!--END !PROJECT_NAME-->
<link href="$relpath^tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="$relpath^jquery.js"></script>
<script type="text/javascript" src="$relpath^dynsections.js"></script>
$treeview
$search
$mathjax
<link href="$relpath^$stylesheet" rel="stylesheet" type="text/css" />
$extrastylesheet
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->

<!--BEGIN TITLEAREA-->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <!--BEGIN PROJECT_LOGO-->
  <td id="projectlogo"><img alt="Logo" src="$relpath^$projectlogo"/></td>
  <!--END PROJECT_LOGO-->
  <!--BEGIN PROJECT_NAME-->
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">$projectname
   <!--BEGIN PROJECT_NUMBER-->&#160;<span id="projectnumber">$projectnumber</span><!--END PROJECT_NUMBER-->
   </div>
   <!--BEGIN PROJECT_BRIEF--><div id="projectbrief">$projectbrief</div><!--END PROJECT_BRIEF-->
  </td>
  <!--END PROJECT_NAME-->
  <!--BEGIN !PROJECT_NAME-->
   <!--BEGIN PROJECT_BRIEF-->
    <td style="padding-left: 0.5em;">
    <div id="projectbrief">$projectbrief</div>
    </td>
   <!--END PROJECT_BRIEF-->
  <!--END !PROJECT_NAME-->
  <!--BEGIN DISABLE_INDEX-->
   <!--BEGIN SEARCHENGINE-->
   <td>$searchbox</td>
   <!--END SEARCHENGINE-->
  <!--END DISABLE_INDEX-->
 </tr>
 </tbody>
</table>
</div>
<!--END TITLEAREA-->
<!-- end header part -->

doc/new_stylesheet.css

0 → 100644
+1596 −0

File added.

Preview size limit exceeded, changes collapsed.

docs/.gitignore

0 → 100644
+1 −0
Original line number Original line Diff line number Diff line
_build/*

docs/CMakeLists.txt

0 → 100644
+24 −0
Original line number Original line Diff line number Diff line
# from https://devblogs.microsoft.com/cppblog/clear-functional-c-documentation-with-sphinx-breathe-doxygen-cmake/
find_package(Doxygen REQUIRED)

# Find all the public headers
get_target_property(CAT_CUTIFIER_PUBLIC_HEADER_DIR CatCutifier INTERFACE_INCLUDE_DIRECTORIES)
file(GLOB_RECURSE CAT_CUTIFIER_PUBLIC_HEADERS ${CAT_CUTIFIER_PUBLIC_HEADER_DIR}/*.h)

set(DOXYGEN_INPUT_DIR ${PROJECT_SOURCE_DIR}/CatCutifier)
set(DOXYGEN_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR}/docs/doxygen)
set(DOXYGEN_INDEX_FILE ${DOXYGEN_OUTPUT_DIR}/html/index.html)
set(DOXYFILE_IN ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in)
set(DOXYFILE_OUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)

#Replace variables inside @@ with the current values
configure_file(${DOXYFILE_IN} ${DOXYFILE_OUT} @ONLY)

file(MAKE_DIRECTORY ${DOXYGEN_OUTPUT_DIR}) #Doxygen won't create this for us
add_custom_command(OUTPUT ${DOXYGEN_INDEX_FILE}
                   DEPENDS ${CAT_CUTIFIER_PUBLIC_HEADERS}
                   COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYFILE_OUT}
                   MAIN_DEPENDENCY ${DOXYFILE_OUT} ${DOXYFILE_IN}
                   COMMENT "Generating docs")

add_custom_target(Doxygen ALL DEPENDS ${DOXYGEN_INDEX_FILE})

docs/InputEvents.rst

0 → 100644
+4 −0
Original line number Original line Diff line number Diff line
Input Event Format
==================

Use Hepmc3

docs/Makefile

0 → 100644
+20 −0
Original line number Original line Diff line number Diff line
# Minimal makefile for Sphinx documentation
#

# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS    ?=
SPHINXBUILD   ?= sphinx-build
SOURCEDIR     = .
BUILDDIR      = _build

# Put it first so that "make" without argument is like "make help".
help:
	@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

.PHONY: help Makefile

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option.  $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
	@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
+107 −0
Original line number Original line Diff line number Diff line
###############
Tips and Tricks
###############

*************
Code Snippets 
*************

Access Variables
################

**Volume ID** from **Cell ID**
******************************

* Volume ID that obtained from Cell ID using dd4hep::VolumeManagerContext.identifier

.. code-block:: cpp

  auto volID = [&] (const std::vector<dd4hep::sim::Geant4Calorimeter::Hit*>& hits) {
        std::vector<double> result;
        for(const auto& h: hits) {
                auto volcontext = cellid_converter.findContext(h->cellID);
                result.push_back(volcontext->identifier);
        }
  return result;
  };

* Volume ID that obtained from Cell ID using dd4hep::VolumeManagerContext.element and Readout/Segmentation 

.. code-block:: cpp

  auto volID = [&] (const std::vector<dd4hep::sim::Geant4Calorimeter::Hit*>& hits) {
        std::vector<double> result;
        for(const auto& h: hits) {
                auto volcontext = cellid_converter.findContext(h->cellID);
                dd4hep::Readout r = cellid_converter.findReadout(volcontext->element);
                dd4hep::Segmentation seg = r.segmentation();
                result.push_back(seg.volumeID(h->cellID));
        }
  return result;
  };


***
FAQ
***

DD4hep
######

What is the difference between **Volume ID** and **Cell ID**?
*************************************************************

  Both are unique IDs, but in the case of volume ID, it is associated with a physical placement of a volume (in G4 or tgeo).
  The cell ID is used to further identify the subgeometry allocated to a volume through a segmentation. 
  The volume ID is related to the cell ID through the readout's ``id`` tag.

  `See dd4hep CellID Descriptors documentation <https://dd4hep.web.cern.ch/dd4hep/usermanuals/DD4hepManual/DD4hepManualch2.html#x3-310002.12.1>`_


What is a **segmentation**?
***************************

  A segmentation is a virtual geometry that is used to subdivide a volume. This 
  avoids creating many small volumes to uniquely identify sensitive elements of 
  a volume. An example would be a silicon detector with many channels at a fine 
  pitch. Instead of create each pixel as a box of silicon, one silicon box is 
  logically divide through the segmentation mechanism of DD4hep. 

  For a list of segmentations `look at the headers in DDSegmentation <https://github.com/AIDASoft/DD4hep/tree/master/DDCore/include/DDSegmentation>`_.


What is a **readout**?
**********************
  A readout is associated with a senstive detector in DD4hep and is used by 
  setting the ``detector``'s ``readout`` attribute.  The attribute value is the 
  name of a readout defined in the ``readouts``.

.. code-block:: XML

  <readouts>
    <readout name="ECalHits">
      <segmentation type="CartesianGridXY" grid_size_x="10.0*cm" grid_size_y="10.0*cm" />
      <id>system:5,layer:9,module:8,x:32:-16,y:-16</id>
    </readout>
  </readouts>

How do I run the GEANT4 simulation?
***********************************

  todo

How can I visualize the GEANT4 simulation?
******************************************

  todo

How can I visualize the detector geometry?
******************************************

  todo





docs/conf.py

0 → 100644
+98 −0

File added.

Preview size limit exceeded, changes collapsed.

docs/contents.rst

0 → 100644
+11 −0
Original line number Original line Diff line number Diff line
.. toctree::
   :maxdepth: 2

   intro
   getting_started
   detectors/detectors
   beamline_magnets
   InputEvents
   Tips_and_Tricks
   topside/topside
   Reference Documentation <https://eic.phy.anl.gov/npdet/ref_doc/>
+5 −0
Original line number Original line Diff line number Diff line
********
Trackers
********

.. include:: RomanPot.rst
+38 −0
Original line number Original line Diff line number Diff line
Getting Started
===============

Installation
------------

Singularity Container
~~~~~~~~~~~~~~~~~~~~~

The easiest way to use this library is the with the `eic_container <https://eicweb.phy.anl.gov/containers/eic_container>`_.

.. warning:: need to add brief instructions here.



Building from source
~~~~~~~~~~~~~~~~~~~~

The following are needed before building `NPDet`

 * `DD4hep <(https://github.com/AIDAsoft/DD4hep>`_
 * `ROOT <https://root.cern.ch>`_
 * `GEANT4 <http://geant4.cern.ch>`_

.. code-block:: bash

   git clone https://eicweb.phy.anl.gov/EIC/NPDet.git
   mkdir npdet_build && cd npdet_build
   cmake ../NPDet/. -DCMAKE_INSTALL_PREFIX=$HOME # or where ever
   make -j4
   make install

Development
-----------


.. warning:: need to add brief how to for container development.

docs/index.rst

0 → 100644
+20 −0

File added.

Preview size limit exceeded, changes collapsed.

docs/intro.rst

0 → 100644
+17 −0

File added.

Preview size limit exceeded, changes collapsed.

docs/make.bat

0 → 100644
+35 −0

File added.

Preview size limit exceeded, changes collapsed.

docs/requirements.txt

0 → 100644
+5 −0

File added.

Preview size limit exceeded, changes collapsed.

+57 −0

File added.

Preview size limit exceeded, changes collapsed.

examples/vis.mac

0 → 100644
+18 −0

File added.

Preview size limit exceeded, changes collapsed.

src/dd4pod/dd4hep.yaml

0 → 100644
+137 −0

File added.

Preview size limit exceeded, changes collapsed.

+8 −0

File added.

Preview size limit exceeded, changes collapsed.

+86 −0

File added.

Preview size limit exceeded, changes collapsed.