Commit Graph
95 Commits
Author SHA1 Message Date
Eberhard Graether 30c941fcf8 logic: crash fixes
<description>
2015-08-07 00:17:41 +02:00
Eberhard Graether 5f25311389 logic: paths in ProjectSettings relative to file not working directory
This change checks all paths in the ProjectSettings file for relativity and makes them relative to the location of the
ProjectSettings file if necessary. The paths are also correctly saved relative to the file.
2015-07-29 22:20:26 +02:00
Eberhard Graether 73aa6080aa ui: clicking snippet title to show full scope
This change lets the user click the snippet title in the CodeView to insert the full scope. The existing snippets are
merged with the new lines accordingly.
2015-07-20 00:57:19 +02:00
Eberhard Graether 85d2ebc32a logic: removed FilterUndefinedNodesFromGraph setting
because it is confusing and not necessary anymore since we have bundled nodes.
2015-07-18 13:46:03 +02:00
Eberhard Graether a527a3c34d logic: rewrote messages handling token activation for correct restoring on undo
* saving search query to undo stack with MessageSearch
* saving node and edge with name to undo stack with MessageActivateNode and MessageActivateEdge
* added FeatureController that handels distribution of MessageActivateTokens
* clearing views when refreshing or changing project
* clearing undo stack when changing project
* added StorageCache derived from StorageAccessProxy
2015-06-19 00:20:50 +02:00
Eberhard Graether d6269f9608 ui: bundling nodes in the graph view
This change bundles similar nodes in the graph view together. When the bundled node or it's aggregation edge are clicked,
then the bundle is split. This change also adds an arrow to the aggregation edge based on the direction of it's edges.
2015-06-17 22:47:08 +02:00
Eberhard Graether 3c6782d94d data: fixed graph display errors
* fixed Storage saving specialized template functions as undefined function node
* fixed usages of same type in functions in return or parameter not clickable in graph, because the edges are on top
2015-06-11 14:04:20 +02:00
Eberhard Graether 0153330317 data: log storage stats after parsing 2015-05-29 16:49:10 +02:00
Eberhard Graether 149bb52c4c data: fixes and improvements
* save forward declarations of classes and structs as NODE_UNDEFINED_TYPE
* put whole files on top in snippet sorting
* uses aggregation count as weight in graph layouting instead of adding all edges to graph
* refreshing all views of components on MessageRefresh in ComponentManager
* reloading ApplikatinoSettings on MessageRefresh
2015-05-25 04:12:52 +02:00
Eberhard Graether 5868fe4d39 ui: minimize and maximize buttons for QtCodeFile
This change switches the code view UI to use minimize and maximize buttons within the QtCodeView instead of creating
separate windows for each maximized code file. Real icons for the buttons are still missing.
2015-05-19 16:27:42 +02:00
Eberhard Graether 1f3be0e60d data: fixes for clearing on refresh
* reduce aggregation count when clearing
* added TokenLocation to method override edge
* added TokenLocations to template related edges
2015-05-18 16:22:39 +02:00
malte_langkabel 97345cc72f ui: scope names in snippet titles
* added title for snippets
* title displays name of parent scope.
* when new TokenLocationFiles are created in the storage they are now returned as shared_ptr to ensure correct linking in the contained data.
* Storage::getTokenLocationsForLinesInFile() now always returns pairs of start and end locations.
* Adjusted code snippet view to regard the change described above.
2015-05-11 12:34:27 +02:00
Eberhard Graether 7dcf8b0bdb src: various fixes
* fixed crash when hovering GraphNode while expanding/collapsing it
* fixed clang warnings
* fixed GraphNodeExpandToggle to show empty circle
* fixed Searchbar showing empty block when nothing was parsed
* made template related edges in GraphView red
2015-05-05 23:12:25 +02:00
malte_langkabel fd73abde64 ui: snippet sizes
* added SnippetMerger class that conducts the merging and snapping of TokenLocations to create snippets.
* added parameters for snippet snapping and merging to ApplicationSettings.
* added forEachStartTokenLocation() and forEachEndTokenLocation() to TokenLocationLine and TokenLocationFile.
* added < and > operators to TokenLocation that compare the location part (not the id).
2015-05-04 15:00:18 +02:00
Eberhard Graether 3c7c3da527 logic: made parsing interruptable by introducing TaskScheduler
This change introduces the TaskScheduler, which queues and processes Tasks on a separate thread. The Task class provides
a common interface for deriving all specific tasks. A task can split it's processing into multiple update calls. The
TaskScheduler will update a task until it is finished or interrupt it when necessary. TaskGroups can be used to bundle
multiple Tasks together. So far only TaskGroupSequential was implemented which runs the Tasks in the set order.

TaskParseCxx utilizes the CxxParser to parse each source file in a single update call. Parsing can be interrupted using
the ESC key. The Statusbar shows the parsing progress.
2015-04-23 18:57:38 +02:00
malte_langkabel bdbd266a67 data: NameHierarchy class
* replaced vector of strings as name hierarchy by a new NameHierarchy class.
* Adjusted code in ASTVisitor, Storage and various test cases.
2015-03-28 16:57:30 +01:00
Eberhard Graether eb9092a07f logic: show whole file in CodeView when file node is active 2015-03-24 23:01:40 +01:00
malte_langkabel 3738f196b9 data: fixed crashed when parsing own code
* fixed test that was expecting a wrong result.
* refactored DataType class.
* added code to parse dependent type names.
* refactored utilityCxx a little.
2015-03-23 17:00:54 +01:00
Eberhard Graether 52baca3962 logic: flag FilterUndefinedNodesFromGraph in ApplicationSettings
If set to true the flag filters all undefined nodes from the graph, unless every active node is undefined.
2015-03-17 15:42:20 +01:00
Eberhard Graether ca85d5a5d3 build: bug fixes for release version
* fixed search activating 2 nodes, because of NodeType in query
* fixed search results didn't contain results with same name
* added protected contents to sample and tictactoe code
* fixed CxxParserTests not logging errors, disabled logging for tests with errors
* fixed CxxParserTests not finding system headers, added TestSettings.xml and pass headers to Parser::parseFile()
2015-03-11 13:14:22 +01:00
malte_langkabel 9b3f9ebdbf data: non-type- and template-template parameters
* name of template class now also contains type information on the template parameters (e.g. typename, class, bool, const std::string&, etc.)
* implemented handling of non-type template parameters and template template parameters.
* implemented lots of tests for these features.
2015-03-09 18:07:30 +01:00
Eberhard Graether ca9dfe7f75 ui: improved file nodes
* added colors for file nodes and dependency edges
* use TokenComponentFilePath on file nodes to store FilePath
2015-03-09 14:07:58 +01:00
Eberhard Graether df888e4151 utility: added FilePath abstraction and rewrote data management to use it
The utility class FilePath wraps an instance of boost::filesystem::path. Using FilePath allows for easy comparision of
file paths on different platforms using absolute or relative paths. Whereever file paths are compared, this wrapper
should be used.
2015-03-09 01:51:32 +01:00
Andreas Stallinger da1a6d69c4 ui: Colors in SearchView
Show the right colors in SearchView for the different NodeTypes or QueryNodeTyps

Note: add colors to your Applcationsettings like in the template

fortune cookie message = recognition will come from unexpected sources
2015-03-04 11:55:25 +01:00
Eberhard Graether 598041f896 data: parsing file dependencies
This change adds the node NODE_FILE to the graph and the edge EDGE_INCLUDE, which determine the dependencies between
files by parsing the include preprocessor directive. File nodes can be searched and displayed in the GraphView as file
dependency graph. The filter "file" allows for selecting all files. The file depency information is used on project
refresh do determine which files need to get reparsed.
2015-03-03 00:33:13 +01:00
malte_langkabel 5370541a0f data: filename info
* Changed the TokenLocation of TemplateArguments to have at least a valid file name.
* Extended name of anonymous namespace by the containing file's name.
* Adjusted tests to reflect these changes.
2015-02-27 16:07:51 +01:00
malte_langkabel d0c92a6553 data: refined template parameter names
* Fixed template parameters to be resolved to their correct names even if they are (re)definied outside of the class (e.g. for template method definitions).
* Added test code.
2015-02-27 14:40:38 +01:00
malte_langkabel 6c3c8cdcc1 data: parsing template functions
* implemented parsing of template functions.
* added tests for those cases.
2015-02-16 16:22:58 +01:00
Eberhard Graether b8f6b4be4e data: added Node type NODE_ENUM_CONSTANT 2015-02-10 14:28:53 +01:00
Eberhard Graether 0b9a2bf4a1 build: fixed clang warnings and console errors 2015-02-10 13:48:20 +01:00
Eberhard Graether 51c6675464 data: parsing and saving method overrides
This change parses method overrides and saves them in the Storage with type EDGE_OVERRIDE.
2015-02-10 12:18:40 +01:00
malte_langkabel 4da51180ca data: fixed crash when parsing initialization of global variable
handled visiting of global variable usage in initialization of another global variable.
2015-02-09 11:20:01 +01:00
Eberhard Graether af1462f955 ui: fixed autocompletion issues
* click in autocompletions list causes search
* right arrow for autocompletion
* changed query operator has from '>' to '.' and operator sub from '.' to '+'
* fixed autocompletions to fit to query
and
* fixed spectral layouting endless looping on unconnected node
2015-02-06 00:51:02 +01:00
malte_langkabel bdcca6dbad data: template arguments default parameters
* implemented parsing of template argument default parameters.
* added tests for default arguments of template parameters.

fortune cookie message = If you continually give, you will continually have.
2015-02-03 16:22:48 +01:00
Eberhard Graether 1690479b0e ui/logic/data: refreshing only source files that have been updated
This change adds the refresh component that allows for refreshing the source code via UI or shortcut. If automatic
refreshing is activated via the UI, the code is refreshed anytime the window gets focus. The contents of all the
updated source files get removed from Storage, before reparsing them. File dependencies are not respected yet.
2015-02-03 14:27:39 +01:00
malte_langkabel e17341fc43 data: parse partial template specializations
* fixed: implicit template specializations will be found even if the original template definition is located in a different file (that gets included).
* implemented correct extraction of template parameters, template arguments and template specialization edges.
* added token locations for template parameters of partial template specializations.
* graph view displays full names of template parameters and template arguments.
* added test code for features
2015-02-03 13:10:56 +01:00
Manuel a7eaeae432 UI: GraphLayouting
Implemented graph layouting, hybrid approach using spectral and force based layouting

fortune cookie message = Giving credit where it's due ensures loyalty to you.
2015-01-29 15:47:02 +01:00
malte_langkabel 4775a87104 data: elaborated type name usage fix
* fixed node name hierarchy creation for elaborated type names (like when using the class namespaceA::B)
2015-01-19 17:22:27 +01:00
Eberhard Graether bdb38acbce ui/logic/data: show parse errors in CodeView
This change saves the errors while parsing in the Storage and displays them in the CodeView. The error messages can be
read in the tooltip on hovering. The error count is visible in the status bar.
2015-01-15 19:38:19 +01:00
Eberhard Graether 7596c699d6 ui: improvements proposed by Julian Mautner
* automatically expand active class
* increase arrow size
* return child nodes in autocompletions
* always return filters in autocompletions
2015-01-12 23:47:57 +01:00
Eberhard Graether 8242454104 ui/data: cleaned up UI and parsing
* HOT FIX: typename not always correctly split to name hierarchy
* show node main if available as first active token after parsing
* show all contents of namespaces if searched for
* added missing enum type and enum value usages
* added inheritance for structs
* removed MessageActivateToken and replaced it with MessageActivateTokens
* activating correct nodes for clicks in GraphView and CodeView
* no graph change when clicking an edge, but highlighting the edge instead
* only show active nodes without connections when multiple are activated
* fixed snippet sorting to put file that contains declarations on top
* set sizeHints on CodeView and SearchView to increase their initial size

fortune cookie message = Das Leben wird eine positive Wendung nehmen.
2015-01-08 12:12:50 +01:00
Eberhard Graether ee85abfc7b data/logic/ui: added aggregation edges
This change adds the creation of aggregation edges to the StorageGraph, which save the connection counts between
children in their parents. Aggregation edges are displayed using a straight line, that is thicker than more connections
it represents with the connection count in the middle.
2015-01-07 14:42:35 +01:00
Eberhard Graether c54c405dd1 logic: fixed warnings, tests and bugs
* fixed clang warnings
* fixed cxxparser tests
* added missing checks for valid location in ASTVisitor callbacks for templates
* removed warning when statusbar view is removed
* made font of activated classes bold
* fixed search box not responding to autocompletion tab or enter press
* fixed search box not updated when active token changes
2014-12-02 00:55:57 +01:00
malte_langkabel 63407c2c81 data: basic template parsing
* Implemented basic parsing and storage of template parameter types, template classes and template functions
* Added template specialization edge.
* Implemented handling of partial specializations. Needs some more tweaking.
* Added a lot of test code for template stuff (still needs some cases to be tested)
* Removed the isTemplateParameterType from DataType, since it shouldn't be needed
* Function qualTypeToDataType uses clang PrintingPolicy to fetch the desired format.
* Merged a lot of code for getting the correct names and name hierarchies of definitions
* Removed TokenComponentDataType
* Merged both of the Storage::addTypeEdge(...) functions
* Added "-fno-delayed-template-parsing" flag to parser for parsing test code.
2014-11-24 16:50:31 +01:00
Eberhard Graether e972dbe098 ui: augmented autocompletion list
This change adds search match information to the autocompletion list:
- matching letters
- color for token or command
- node type as string
2014-11-02 17:21:51 +01:00
Andreas Stallinger 250918a4e7 logic: Configmanager support for lists
Configmanager now works with list. Use getValues for list. Configmanager
is able to save into a file now.
2014-10-30 14:22:28 +01:00
Eberhard Graether 2c84bf20ed data: split off inner classes of SearchIndex 2014-10-28 22:06:22 +01:00
Eberhard Graether 86f4629b0d logic: preselecting SearchNodes for autocompletion by prefiltering the Graph with the entered Query
This change only shows matches in the autocompletion list that are prefiltered by the already entered query. The
autocompletion now also shows up after an operator of type . or > has been entered to show an alphabetical list of
possible tokens.
2014-10-28 20:21:19 +01:00
Andreas Stallinger 0a4c65d198 logic: Codeview Snippet order
Sorting the Snippets in. the Codeview. Active Token first then declaration,
filename and extension
2014-10-24 13:37:06 +02:00
malte_langkabel a1b874c520 data: name hierarchy refactoring
* replaced typenames (which have been stored as single sting where "::" indicated hierarchy levels) by a vector of strings where each element indicates a hierarchy level.
* introduced this change to the Storage method signatures, the ParseFunction and ParseVariable
* this way the SearchIndex creates a node for each level of the hierarchy.
2014-10-24 11:25:34 +02:00