Skip to content

Commit 869785f

Browse files
committed
clarify linux and demo setup
1 parent 7590260 commit 869785f

File tree

3 files changed

+95
-13
lines changed

3 files changed

+95
-13
lines changed

api-docs/source/_static/css/other.css

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1+
/*
12
.wy-nav-content {
23
max-width: 2000px !important;
34
}
5+
*/
46

57
.cpplink, .cpplink a, .cpplink a:visited{
68
color: #fff;
@@ -14,3 +16,79 @@
1416
.colon {
1517
display: none !important;
1618
}
19+
20+
21+
.toctree-l1 a:visited,
22+
.toctree-l1 a:hover,
23+
.toctree-l1 a {
24+
color: #ccc;
25+
}
26+
27+
.wy-nav-top {
28+
background-color: #d73726 !important;
29+
color: #fff !important;
30+
}
31+
32+
.wy-nav-top a:visited,
33+
.wy-nav-top a:hover,
34+
.wy-nav-top a,
35+
.wy-side-nav-search a:visited,
36+
.wy-side-nav-search a:hover,
37+
.wy-side-nav-search a {
38+
color: #fff;
39+
}
40+
41+
.md-header {
42+
background-color: #d73726;
43+
}
44+
45+
.md-tabs {
46+
background-color: #d73726;
47+
color: #ffffff;
48+
}
49+
50+
.headerlink,
51+
.md-typeset a,
52+
.md-nav__link,
53+
.md-nav__item {
54+
color: #d73726;
55+
}
56+
57+
a.md-tabs__link,
58+
a.md_tabs__link:visited {
59+
color: #ffffff;
60+
}
61+
62+
.md_tabs__link:hover {
63+
color: #cccccc;
64+
}
65+
66+
.headerlink:hover,
67+
.md-typeset a:hover,
68+
.md-nav__link:hover,
69+
.md-nav__item:hover {
70+
color: #000000;
71+
}
72+
73+
.md-source,
74+
.md-source:visited,
75+
.md-header__button,
76+
.md-header__button:visited {
77+
color: #ffffff;
78+
}
79+
80+
.md-grid {
81+
max-width: 85%;
82+
}
83+
84+
/* TODO: Cleanup above hacks and replace with fully theme-aware code like below. */
85+
86+
[data-md-color-scheme="binja"] {
87+
--md-primary-fg-color: #d73726;
88+
--md-primary-bg-color: #ffffff;
89+
--md-primary-fg-color--light: #ECB7B7;
90+
--md-primary-fg-color--dark: #990000;
91+
--md-code-fg-color: rgb(215, 55, 38);
92+
--md-code-bg-color: hsla(0, 0%, 96%, 1);
93+
--md-typeset-a-color: #000000;
94+
}

api-docs/source/conf.py

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def modulelist(module, basename=""):
5959
modules = inspect.getmembers(module, inspect.ismodule)
6060
# We block the module named "debugger", because it is the folder that contains all debugger Python files
6161
moduleblacklist = ["binaryninja", "core", "_binaryninjacore", "associateddatastore",
62-
"dbgcore", "_debuggercore", "_collaboration"]
62+
"dbgcore", "_debuggercore", "_collaboration", "_ty"]
6363
if basename != "":
6464
basename += "."
6565

@@ -181,10 +181,12 @@ def generaterst():
181181
'sphinx.ext.intersphinx',
182182
'sphinxcontrib.jquery',
183183
#'sphinx_tabs.tabs',
184-
'sphinx.ext.viewcode'
184+
'sphinx.ext.viewcode',
185+
'sphinx_immaterial',
185186
]
186187

187188
simplify_optional_unions = True
189+
autoclass_content = 'both'
188190
autodoc_typehints = 'both'
189191
autosummary_generate = False
190192
autodoc_member_order = 'groupwise'
@@ -211,7 +213,7 @@ def generaterst():
211213

212214
# General information about the project.
213215
project = u'Binary Ninja Python API'
214-
copyright = u'2015-2023, Vector 35 Inc'
216+
copyright = u'2015-2024, Vector 35 Inc'
215217
author = u'Vector 35 Inc'
216218

217219
# The version info for the project you're documenting, acts as replacement for
@@ -253,22 +255,22 @@ def generaterst():
253255
# The theme to use for HTML and HTML Help pages. See the documentation for
254256
# a list of builtin themes.
255257
#
256-
html_theme = 'sphinx_rtd'
257-
html_theme_path = [os.path.join(os.path.abspath("."), "..", "..")]
258+
html_theme = 'sphinx_immaterial'
259+
#html_theme_path = [os.path.join(os.path.abspath("."), "..", "..")]
258260

259261
# Theme options are theme-specific and customize the look and feel of a theme
260262
# further. For a list of options available for each theme, see the
261263
# documentation.
262264
#
263265
html_theme_options = {
264-
'display_version': True,
265-
'style_external_links': True,
266-
'collapse_navigation': True, #Change to have all modules expandable from the start
267-
'navigation_depth': 2,
268-
'titles_only': False,
269-
'sticky_navigation': False,
266+
'features': ['navigation.tracking', 'navigation.expand', 'toc.follow'],
267+
"palette": { "scheme": "binja", "accent": "red" }
270268
}
271269

270+
object_description_options = [
271+
("py:parameter", dict(include_fields_in_toc=False)),
272+
]
273+
272274
# Add any paths that contain custom themes here, relative to this directory.
273275
# html_theme_path = []
274276

@@ -279,7 +281,7 @@ def generaterst():
279281

280282
# A shorter title for the navigation bar. Default is the same as html_title.
281283
#
282-
html_short_title = u'BN API'
284+
html_short_title = u'Binary Ninja Python API Reference'
283285

284286
# The name of an image file (relative to this directory) to place at the top
285287
# of the sidebar.

docs/getting-started.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,11 @@ Welcome to Binary Ninja. This introduction document is meant to quickly guide yo
66
## Installing Binary Ninja
77

88
The download links you receive after purchasing expire after 72 hours but as long as you have [active support](https://binary.ninja/faq/#updates) you can [request download links](https://binary.ninja/recover/) any time!
9+
910
### Linux
1011

11-
Because Linux install locations can vary widely, we do not assume that Binary Ninja has been installed in any particular folder on Linux. Instead, first unzip the installation zip wherever you wish to install BN, and then run `binaryninja/scripts/linux-setup.sh`. This sets up file associations, icons, and adds BN's Python library to your python path. Run it with `-h` to see the customization options.
12+
Because Linux install locations can vary widely, we do not assume that Binary Ninja has been installed in any particular folder on Linux. Instead, first unzip the installation zip wherever you wish to install BN. Next, for paid versions, run `./binaryninja/scripts/linux-setup.sh`. This sets up file associations, icons, and adds BN's Python library to your python path. Adding the library to your path is most helpful for headless functionality in commercial licenses, but even on non-commercial plugins it can help IDE's find the type information to make plugin development easier. Run the script with `-h` to see customization options.
13+
1214
### MacOS
1315

1416
To install on MacOS, simply drag-and-drop the app bundle from the DMG to the desired location.

0 commit comments

Comments
 (0)