├── widgets.gif ├── notebooks ├── marie.png ├── Big.Buck.Bunny.mp3 └── Big.Buck.Bunny.mp4 ├── docs ├── source │ ├── _static │ │ └── main_stylesheet.css │ ├── conf.py │ ├── releasing.rst │ ├── installation.rst │ ├── embed_widgets │ │ ├── xleaflet_example.ipynb │ │ └── xplot_example.ipynb │ ├── conda.svg │ ├── index.rst │ ├── compilers.rst │ ├── xplot.svg │ ├── xwidgets.svg │ ├── xproperty.svg │ ├── related_projects.rst │ └── quantstack-white.svg ├── environment.yml └── Doxyfile ├── environment.yml ├── readthedocs.yml ├── src ├── xplay.cpp ├── xlabel.cpp ├── xoutput.cpp ├── xdropdown.cpp ├── xpassword.cpp ├── xtextarea.cpp ├── xaccordion.cpp ├── xcolor_picker.cpp ├── xradiobuttons.cpp ├── xhtml.cpp ├── xlink.cpp ├── xselect.cpp ├── xselectionslider.cpp ├── xcontroller.cpp ├── xtab.cpp ├── xaudio.cpp ├── ximage.cpp ├── xmedia.cpp ├── xvalid.cpp ├── xvideo.cpp ├── xlayout.cpp ├── xmixin_description.cpp ├── xtext.cpp ├── xbutton.cpp ├── xcheckbox.cpp ├── xtogglebutton.cpp ├── xtogglebuttons.cpp ├── xbox.cpp ├── xnumber.cpp ├── xtarget.hpp ├── xnumber_bounded.cpp ├── xslider.cpp ├── xprogress.cpp ├── xfactory.cpp ├── xregistry.cpp ├── xholder_id.cpp ├── xholder.cpp └── xbinary.cpp ├── environment-dev.yml ├── test ├── main.cpp ├── CMakeLists.txt └── test_xholder.cpp ├── include └── xwidgets │ ├── xcolor.hpp │ ├── xwidgets_config_cling.hpp.in │ ├── xmaker.hpp │ ├── xbinary.hpp │ ├── xjson.hpp │ ├── xfactory.hpp │ ├── xeither.hpp │ ├── xstyle.hpp │ ├── xregistry.hpp │ ├── xtab.hpp │ ├── xaccordion.hpp │ ├── xvalid.hpp │ ├── xboolean.hpp │ ├── xwidget.hpp │ ├── xpassword.hpp │ ├── xall.hpp │ ├── xobject.hpp │ ├── xdropdown.hpp │ ├── xstring.hpp │ ├── xradiobuttons.hpp │ ├── xtextarea.hpp │ ├── xmedia.hpp │ ├── xselection_container.hpp │ ├── xcolor_picker.hpp │ ├── ximage.hpp │ ├── xaudio.hpp │ ├── xplay.hpp │ ├── xoutput.hpp │ ├── xnumber.hpp │ ├── xvideo.hpp │ ├── xmaterialize.hpp │ ├── xnumber_bounded.hpp │ ├── xmixin_description.hpp │ ├── xcheckbox.hpp │ └── xhtml.hpp ├── .gitignore ├── .cmake-format.json ├── .pre-commit-config.yaml ├── LICENSE ├── xwidgetsConfig.cmake.in ├── .clang-format ├── binder-logo.svg ├── .github └── workflows │ └── main.yml └── README.md /widgets.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jupyter-xeus/xwidgets/HEAD/widgets.gif -------------------------------------------------------------------------------- /notebooks/marie.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jupyter-xeus/xwidgets/HEAD/notebooks/marie.png -------------------------------------------------------------------------------- /notebooks/Big.Buck.Bunny.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jupyter-xeus/xwidgets/HEAD/notebooks/Big.Buck.Bunny.mp3 -------------------------------------------------------------------------------- /notebooks/Big.Buck.Bunny.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jupyter-xeus/xwidgets/HEAD/notebooks/Big.Buck.Bunny.mp4 -------------------------------------------------------------------------------- /docs/source/_static/main_stylesheet.css: -------------------------------------------------------------------------------- 1 | .wy-nav-content{ 2 | max-width: 1000px; 3 | margin: auto; 4 | } 5 | -------------------------------------------------------------------------------- /docs/environment.yml: -------------------------------------------------------------------------------- 1 | name: xwidgets-docs 2 | 3 | channels: 4 | - conda-forge 5 | 6 | dependencies: 7 | - breathe 8 | - sphinx_rtd_theme 9 | -------------------------------------------------------------------------------- /environment.yml: -------------------------------------------------------------------------------- 1 | name: xwidgets 2 | channels: 3 | - conda-forge 4 | dependencies: 5 | - xeus-cling=0.13.0 6 | - xwidgets=0.26.1 7 | - widgetsnbextension >=3.0.0 8 | -------------------------------------------------------------------------------- /readthedocs.yml: -------------------------------------------------------------------------------- 1 | version: 2 2 | 3 | build: 4 | os: ubuntu-22.04 5 | tools: 6 | python: mambaforge-22.9 7 | 8 | conda: 9 | environment: docs/environment.yml 10 | -------------------------------------------------------------------------------- /src/xplay.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xplay.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xlabel.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xlabel.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xoutput.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xoutput.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xdropdown.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xdropdown.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xpassword.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xpassword.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xtextarea.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xtextarea.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xaccordion.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xaccordion.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xcolor_picker.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xcolor_picker.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xradiobuttons.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xradiobuttons.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | } 8 | -------------------------------------------------------------------------------- /src/xhtml.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xhtml.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | 8 | template class XWIDGETS_API xmaterialize; 9 | template class XWIDGETS_API xtransport>; 10 | } 11 | -------------------------------------------------------------------------------- /src/xlink.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xlink.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | 8 | template class XWIDGETS_API xmaterialize; 9 | template class XWIDGETS_API xtransport>; 10 | } 11 | -------------------------------------------------------------------------------- /src/xselect.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xselect.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | 8 | template class XWIDGETS_API xmaterialize; 9 | template class XWIDGETS_API xtransport>; 10 | } 11 | -------------------------------------------------------------------------------- /environment-dev.yml: -------------------------------------------------------------------------------- 1 | name: xwidgets 2 | channels: 3 | - conda-forge 4 | dependencies: 5 | # Build dependencies 6 | - cmake <4 7 | - cxx-compiler 8 | - ninja 9 | # Host dependencies 10 | - xeus>=5.0.0,<6 11 | - xproperty=0.12.1 12 | - nlohmann_json=3.12.0 13 | # Test dependencies 14 | - doctest >= 2.4.6 15 | - json_schema_validator 16 | - pre-commit 17 | - cmake-format 18 | -------------------------------------------------------------------------------- /docs/Doxyfile: -------------------------------------------------------------------------------- 1 | PROJECT_NAME = "xwidgets" 2 | XML_OUTPUT = xml 3 | INPUT = ../include 4 | GENERATE_LATEX = NO 5 | GENERATE_MAN = NO 6 | GENERATE_RTF = NO 7 | CASE_SENSE_NAMES = NO 8 | GENERATE_HTML = NO 9 | GENERATE_XML = YES 10 | RECURSIVE = YES 11 | QUIET = YES 12 | JAVADOC_AUTOBRIEF = YES 13 | WARN_IF_UNDOCUMENTED = NO 14 | -------------------------------------------------------------------------------- /src/xselectionslider.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xselectionslider.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | 8 | template class XWIDGETS_API xmaterialize; 9 | template class XWIDGETS_API xtransport>; 10 | } 11 | -------------------------------------------------------------------------------- /src/xcontroller.cpp: -------------------------------------------------------------------------------- 1 | #include "xwidgets/xcontroller.hpp" 2 | 3 | namespace xw 4 | { 5 | template class XWIDGETS_API xmaterialize; 6 | template class XWIDGETS_API xtransport>; 7 | 8 | template class XWIDGETS_API xmaterialize; 9 | template class XWIDGETS_API xtransport>; 10 | 11 | template class XWIDGETS_API xmaterialize; 12 | template class XWIDGETS_API xtransport>; 13 | } 14 | -------------------------------------------------------------------------------- /test/main.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2016, Johan Mabille and Sylvain Corlay * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN 10 | 11 | #include 12 | -------------------------------------------------------------------------------- /src/xtab.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2017, Sylvain Corlay and Johan Mabille * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xtab.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /include/xwidgets/xcolor.hpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2017, Sylvain Corlay and Johan Mabille * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #ifndef XWIDGETS_COLOR_HPP 10 | #define XWIDGETS_COLOR_HPP 11 | 12 | #include 13 | 14 | namespace xw 15 | { 16 | using html_color = std::string; 17 | } 18 | #endif 19 | -------------------------------------------------------------------------------- /src/xaudio.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xaudio.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /src/ximage.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/ximage.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /src/xmedia.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xmedia.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /src/xvalid.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xvalid.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /src/xvideo.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xvideo.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /src/xlayout.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xlayout.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /src/xmixin_description.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xmixin_description.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | } 16 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Prerequisites 2 | *.d 3 | 4 | # Compiled Object files 5 | *.slo 6 | *.lo 7 | *.o 8 | *.obj 9 | 10 | # Precompiled Headers 11 | *.gch 12 | *.pch 13 | 14 | # Compiled Dynamic libraries 15 | *.so 16 | *.dylib 17 | *.dll 18 | 19 | # Compiled Static libraries 20 | *.lai 21 | *.la 22 | *.a 23 | *.lib 24 | 25 | # Executables 26 | *.exe 27 | *.out 28 | *.app 29 | 30 | # Vim tmp files 31 | *.swp 32 | 33 | # Build directory 34 | build/ 35 | 36 | # Test build artefacts 37 | test/test_xwidgets 38 | test/CMakeCache.txt 39 | test/Makefile 40 | test/CMakeFiles/ 41 | test/cmake_install.cmake 42 | 43 | # Documentation build artefacts 44 | docs/CMakeCache.txt 45 | docs/xml/ 46 | docs/build/ 47 | 48 | # Jupyter artefacts 49 | .ipynb_checkpoints/ 50 | 51 | # Generated files 52 | *.pc 53 | 54 | # Generated header 55 | include/xwidgets/xwidgets_config_cling.hpp 56 | -------------------------------------------------------------------------------- /.cmake-format.json: -------------------------------------------------------------------------------- 1 | { 2 | "encode": { 3 | "emit_byteorder_mark": false, 4 | "input_encoding": "utf-8", 5 | "output_encoding": "utf-8" 6 | }, 7 | "format": { 8 | "always_wrap": [], 9 | "autosort": false, 10 | "command_case": "lower", 11 | "dangle_align": "prefix", 12 | "dangle_parens": true, 13 | "enable_sort": true, 14 | "keyword_case": "upper", 15 | "layout_passes": {}, 16 | "line_ending": "unix", 17 | "line_width": 110, 18 | "max_lines_hwrap": 0, 19 | "max_pargs_hwrap": 6, 20 | "max_prefix_chars": 0, 21 | "max_rows_cmdline": 1, 22 | "max_subgroups_hwrap": 2, 23 | "min_prefix_chars": 0, 24 | "require_valid_layout": false, 25 | "separate_ctrl_name_with_space": false, 26 | "separate_fn_name_with_space": false, 27 | "tab_size": 4 28 | }, 29 | "misc": { 30 | "per_command": {} 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/xtext.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xtext.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | } 19 | -------------------------------------------------------------------------------- /src/xbutton.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xbutton.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | } 19 | -------------------------------------------------------------------------------- /src/xcheckbox.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xcheckbox.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | } 19 | -------------------------------------------------------------------------------- /src/xtogglebutton.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xtogglebutton.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | } 19 | -------------------------------------------------------------------------------- /src/xtogglebuttons.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xtogglebuttons.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | } 19 | -------------------------------------------------------------------------------- /src/xbox.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2017, Sylvain Corlay and Johan Mabille * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xbox.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | 19 | template class XWIDGETS_API xmaterialize; 20 | template class XWIDGETS_API xtransport>; 21 | } 22 | -------------------------------------------------------------------------------- /docs/source/conf.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | # -*- coding: utf-8 -*- 3 | 4 | import os 5 | import subprocess 6 | 7 | on_rtd = os.environ.get('READTHEDOCS', None) == 'True' 8 | 9 | if on_rtd: 10 | subprocess.call('cd ..; doxygen', shell=True) 11 | 12 | import sphinx_rtd_theme 13 | 14 | 15 | def setup(app): 16 | app.add_css_file("main_stylesheet.css") 17 | 18 | html_theme = "sphinx_rtd_theme" 19 | 20 | html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] 21 | 22 | extensions = ['breathe', 'sphinx_rtd_theme'] 23 | breathe_projects = { 'xwidgets': '../xml' } 24 | templates_path = ['_templates'] 25 | html_static_path = ['_static'] 26 | source_suffix = '.rst' 27 | master_doc = 'index' 28 | project = 'xwidgets' 29 | copyright = '2017, Johan Mabille and Sylvain Corlay' 30 | author = 'Johan Mabille and Sylvain Corlay' 31 | 32 | html_logo = 'quantstack-white.svg' 33 | 34 | exclude_patterns = [] 35 | highlight_language = 'c++' 36 | pygments_style = 'sphinx' 37 | todo_include_todos = False 38 | htmlhelp_basename = 'xwidgetsdoc' 39 | -------------------------------------------------------------------------------- /src/xnumber.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xnumber.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | 19 | template class XWIDGETS_API xmaterialize; 20 | template class XWIDGETS_API xtransport>; 21 | } 22 | -------------------------------------------------------------------------------- /src/xtarget.hpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2017, Sylvain Corlay and Johan Mabille * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #ifndef XWIDGETS_TARGET_HPP 10 | #define XWIDGETS_TARGET_HPP 11 | 12 | #include 13 | 14 | namespace xw 15 | { 16 | /** 17 | * Return the ``jupyter.widget`` Xeus target. 18 | * 19 | * This target is used by the comms of the widgets to synchronize state between the frontend 20 | * (_e.g._ jupyterlab) and the backend (kernel). 21 | * This function will register the target with Xeus upon first call. 22 | */ 23 | xeus::xtarget* get_widget_target(); 24 | } 25 | 26 | #endif 27 | -------------------------------------------------------------------------------- /src/xnumber_bounded.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xnumber_bounded.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | 19 | template class XWIDGETS_API xmaterialize; 20 | template class XWIDGETS_API xtransport>; 21 | } 22 | -------------------------------------------------------------------------------- /include/xwidgets/xwidgets_config_cling.hpp.in: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2017, Sylvain Corlay and Johan Mabille * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #ifndef XWIDGETS_CONFIG_CLING_HPP 10 | #define XWIDGETS_CONFIG_CLING_HPP 11 | 12 | #ifdef __CLING__ 13 | 14 | #pragma cling add_library_path(@XWIDGETS_INSTALL_LIBRARY_DIR@) 15 | #pragma cling load("libxwidgets") 16 | 17 | #elif defined(__EMSCRIPTEN__) && defined(__CLANG_REPL__) 18 | 19 | #include 20 | static bool _xwidgets_loaded = []() { 21 | Cpp::LoadLibrary("/lib/@CMAKE_SHARED_LIBRARY_PREFIX@xwidgets@CMAKE_SHARED_LIBRARY_SUFFIX@", false); 22 | return true; 23 | }(); 24 | 25 | #endif 26 | 27 | #endif // XWIDGETS_CONFIG_CLING_HPP 28 | -------------------------------------------------------------------------------- /docs/source/releasing.rst: -------------------------------------------------------------------------------- 1 | .. Copyright (c) 2017, Johan Mabille and Sylvain Corlay 2 | 3 | Distributed under the terms of the BSD 3-Clause License. 4 | 5 | The full license is in the file LICENSE, distributed with this software. 6 | 7 | Releasing xwidgets 8 | ================== 9 | 10 | Releasing a new version 11 | ----------------------- 12 | 13 | From the master branch of xwidgets 14 | 15 | - Make sure that you are in sync with the master branch of the upstream remote. 16 | - In file ``xwidgets_config.hpp``, set the macros for ``XWIDGETS_VERSION_MAJOR``, ``XWIDGETS_VERSION_MINOR`` and ``XWIDGETS_VERSION_PATCH`` to the desired values. 17 | - Update the README file w.r.t. dependencies on xwidgets. 18 | - Update the environment.yml file used by binder with the new version of 19 | xwidgets and dependencies. 20 | - Stage the changes (``git add``), commit the changes (``git commit``) and add a tag of the form ``Major.minor.patch``. It is important to not add any other content to the tag name. 21 | - Push the new commit and tag to the main repository. (``git push``, and ``git push --tags``) 22 | - Release xwidgets on conda. 23 | - Update the stable branch to point to the latest tag. 24 | -------------------------------------------------------------------------------- /src/xslider.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xslider.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | 19 | template class XWIDGETS_API xmaterialize; 20 | template class XWIDGETS_API xtransport>; 21 | 22 | template class XWIDGETS_API xmaterialize; 23 | template class XWIDGETS_API xtransport>; 24 | } 25 | -------------------------------------------------------------------------------- /src/xprogress.cpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2022, QuantStack and XWidgets contributors * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #include "xwidgets/xprogress.hpp" 10 | 11 | namespace xw 12 | { 13 | template class XWIDGETS_API xmaterialize; 14 | template class XWIDGETS_API xtransport>; 15 | 16 | template class XWIDGETS_API xmaterialize; 17 | template class XWIDGETS_API xtransport>; 18 | 19 | template class XWIDGETS_API xmaterialize; 20 | template class XWIDGETS_API xtransport>; 21 | 22 | template class XWIDGETS_API xmaterialize; 23 | template class XWIDGETS_API xtransport>; 24 | } 25 | -------------------------------------------------------------------------------- /include/xwidgets/xmaker.hpp: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (c) 2017, Sylvain Corlay and Johan Mabille * 3 | * * 4 | * Distributed under the terms of the BSD 3-Clause License. * 5 | * * 6 | * The full license is in the file LICENSE, distributed with this software. * 7 | ****************************************************************************/ 8 | 9 | #ifndef XWIDGETS_MAKER_HPP 10 | #define XWIDGETS_MAKER_HPP 11 | 12 | #include "nlohmann/json.hpp" 13 | #include "xeus/xcomm.hpp" 14 | #include "xeus/xmessage.hpp" 15 | #include "xholder.hpp" 16 | #include "xmaterialize.hpp" 17 | #include "xregistry.hpp" 18 | 19 | namespace nl = nlohmann; 20 | 21 | namespace xw 22 | { 23 | /******************* 24 | * xmaker template * 25 | *******************/ 26 | 27 | template