Commit Graph

3663 Commits (7cea0344b28125c5afbff74c234d4c942597f552)

Author SHA1 Message Date
elsid c8402c0b14
Avoid double assignment on info saving 2 years ago
elsid 0d523c3793
Log loading errors 2 years ago
elsid 9598b26462
Make loading error messages copyable 2 years ago
elsid 6f6e452dfa
Add executable to run CS tests 2 years ago
elsid 59f2fccc9f
Split openmw-cs into binary and library 2 years ago
elsid 1cc4909144
Add --coverage to components_qt, benchmarks and openmw-cs 2 years ago
elsid d03bec60e9
Avoid redundant conversion from RefId to string and back 2 years ago
elsid 191f207e78
Avoid redundant conversion to lower case for CommandDispatcher::mSelection items 2 years ago
elsid 7daef583cb
Use ESM::RefId as key for ScriptContext::mLocals 2 years ago
elsid 693f4c40f4
Use ESM::RefId as key for Data::mRefLoadCache 2 years ago
elsid 419a86f0b9
Use ESM::RefId for actor parts
To avoid redundant conversion RefId to string and back.
2 years ago
elsid 4cb095ce39
Use ESM::RefId as key for MergeReferencesStage::mIndex 2 years ago
elsid 3c9dbb11cc
Use ESM::RefId as key for SavingState::mSubRecords 2 years ago
elsid dfcea389be
Add helper functions for string comparison to RefId 2 years ago
elsid c03d3360d9
Remove redundant virtual modifiers, add override and final modifiers 2 years ago
elsid a09612264c
Fix setRecordId overload declaration
To match other declarations arguments order.
2 years ago
elsid 4ed0960856
Remove redundant IdAccessor type
Use overloaded free functions instead.
2 years ago
elsid b5ec584be2
Replace ESM::RefId::sEmpty by default constructed RefId where possible
Static const is only required to provide a reference or a pointer when it is not
possible with default constructed temporary.
2 years ago
psi29a d846a9fc15 Merge branch 'cs_optimize_saving' into 'master'
Fix editor saving performance

See merge request OpenMW/openmw!2741
2 years ago
elsid e618026c69
Use ESM::RefId as index key in collections 2 years ago
elsid b2299ef914
Optimize saving in editor 2 years ago
elsid 8383fa3547
Log time spent on document operations in editor 2 years ago
psi29a 18d488d968 Merge branch 'ref_id_class' into 'master'
Convert RefId to class

See merge request OpenMW/openmw!2739
2 years ago
elsid 996153f78d
Convert RefId to class 2 years ago
elsid b6a2fd8fc1
Simplify InfoCollection
There was additional logic to create topic infos index by topic id to make
getTopicInfos and removeDialogueInfos functions faster. In practice it makes
loading slower.

Move infos index by topic to CSMWorld::Data and use only on loading.
2 years ago
elsid de24cdc12c
Log content files loading time by editor 2 years ago
elsid 080700f8fe
Name all custom ESM format versions and add tests 2 years ago
psi29a 944931c9bf Merge branch 'load_esm4_lights' into 'master'
Adds ESM4 light into ESM4 Cells

See merge request OpenMW/openmw!2692
2 years ago
Andrei Kortunov 9ad0e2f4e6 Migrate Grow Limit editor feature to a more modern code 2 years ago
florent.teppe 486d15b19e moved light common to its own file
moved esm4light to it's own file
2 years ago
florent.teppe dc961e3189 Adds the light into the scene.
Common struct for ESM3 and ESM4 light
2 years ago
psi29a a0795ba7ae Merge branch 'launch_fix' into 'master'
Fix some non-ASCII path issues

Closes #6817

See merge request OpenMW/openmw!2686
2 years ago
Andrei Kortunov 7e2aedf637 Add an initial Qt6 support 2 years ago
Andrei Kortunov 5836d27928 Fix ContentSelector usage with non-ASCII paths 2 years ago
unelsson fe70285ac1 Fixes 2 years ago
psi29a 3f9cae7947 Merge branch 'dragdetails' into 'master'
[OpenMW-CS] Generate record filters based on cell content and column header

Closes #7161

See merge request OpenMW/openmw!2617
2 years ago
elsid c44bc5ade5
Setup logging with properly initialized configuration manager
Default constructed instance may provide different paths from initialized one.
2 years ago
unelsson 5bbe9bc5d8 cleanup and style (const ref instead of value, consistent ifndef naming) 2 years ago
unelsson 6b0998ff85 Implement enum class FilterType 2 years ago
unelsson 2e7d41373b Remove unused includes, fix std::get logic at editwidget 2 years ago
unelsson 2fac4d0e40 Use struct with sensible member names 2 years ago
unelsson 9b808a495c Use std::variant and std::visit instead of function overloads, add float type search, fix QMetaType and Type conversion 2 years ago
florent.teppe 3780033837 Reverts Cell name to a string 2 years ago
unelsson ba6c47bb07 Implement record filter search by value and QVariant type recognition 2 years ago
unelsson fc64ab0f5a Promise constness 2 years ago
unelsson 6a864cd9f6 Implement basic filter generation from the dragged table cell (cell content and column header) 2 years ago
unelsson bc1027ee95 First draft of getting the exact drag start location 2 years ago
Andrei Kortunov cc1c8b2bb1 Do not use a deprecated way to get dimensions of screen where current widget is located 2 years ago
Andrei Kortunov 99a575b663 Init QVariant in Qt6-compatible way 2 years ago
Andrei Kortunov 0b3ba26d86 Init style in Qt6-compatible way 2 years ago
Andrei Kortunov 0de635dcdc Do not use deprecated init() method 2 years ago
unelsson 50726636ba clang-format 2 years ago
unelsson 7fce4bc8c4 Issue command passing through QLineInput 2 years ago
unelsson 0310b1cddf Dragging Topics to TopicInfo window opens create TopicInfo BottomBox with the correct id 2 years ago
unelsson 7f8a84f2f2 Move Response column earlier 2 years ago
psi29a 203eb80afd Merge branch 'qregexp' into 'master'
Simplify regex search in the editor

See merge request OpenMW/openmw!2610
2 years ago
Andrei Kortunov 7c8fb79745 Suppress a warnings spam when user entered an invalid regular expression 2 years ago
Andrei Kortunov 7c709167d9 Simplify regex search in the editor 2 years ago
jvoisin 853ca5827e Simplify a regex and fix a typo
- The usage of `|` is wrong
- It's `mWhiteListQuotes` and not `mWhiteListQoutes`
- Replace weird usage of `{}`-based quantifiers
2 years ago
Andrei Kortunov 307a60e87c Migrate from QRegExp to more modern QRegularExpression 2 years ago
elsid c173348cbe
Use default initializers for ESM::RefNum members
Instead of unset function that is removed now and assignments all over the code.
2 years ago
florent.teppe 0de6b79966 Fixes issue with topic info edition.
Also future proofs reference on RefId's string.
2 years ago
florent.teppe 1b66be9c70 Fix dangling reference. 2 years ago
florent.teppe 1ef1de974d script blacklist => RefId
Applies changes from review

Fixed clang format

Clang format + review.
2 years ago
florent.teppe 2c30575b3b CellName is now a RefId, makes more sense that way. 2 years ago
florent.teppe 6ff90b34a8 Fixed an issue with RefId in CellRefs where Ids wouldn't be loaded
Fixed multiple issues from the review.
2 years ago
florent.teppe 0f3499f504 Renamed string => Id, makes more sense considering the new underlying type
Fixes unnecessary copies, and issues with case sensitive comparisons.

fixed modification that wasn't necessary

Fixed type mismatch, and unecessary copy
2 years ago
florent.teppe 30a020883e Avoids unecessary copies
Fixed issue with lowerCase

Oups fixed compialtion on openMW_test_suite
2 years ago
florent.teppe 65cdd489fb create a specific esm reader function for RefID to avoid allocation for string and then again for RefId
Fixed some types

removed useless header

applied clang format

fixed compile tests

fixed clang tidy, and closer to logic before this MR

Removed hardcoded refids

unless there is a returned value we don't use static RefIds
can use == between RefId and hardcoded string

Fix clang format

Fixed a few instances where std::string was used, when only const std::string& was needed

removed unused variable
2 years ago
fteppe 09d461a8cd fixed Topic selected event
Fix rebase
2 years ago
fteppe 62d8fe3fc2 changed a few hardcoded refIds used in mutliple places to be defined only once in a variable 2 years ago
fteppe 20da0892ef openMW_test_suite compiles and runs
Slowly moving through the open-cs errors

Good progress in openCS

Very good progress on openCS

Getting closer with openCS

OpenCS compiles and runs! Didn't have time to test it all though

ix openMW

everything compiles on windows??

Fix gcc

Fix Clang
2 years ago
psi29a fa50890633 Merge branch 'sm-snap-to-reference' into 'master'
Open-CS: Snap to Reference

See merge request OpenMW/openmw!2484
2 years ago
Petr Mikheev 6025943fed Add missing content=builtin.omwscripts if openmw is started via openmw-cs (fixes #7056) 2 years ago
Max Henzerling 897cdc62d8 Add snap to reference 2 years ago
psi29a 6960fc9304 Merge branch 'opencs_iwyu' into 'master'
Run IWYU on the opencs

See merge request OpenMW/openmw!2481
2 years ago
Evil Eye 45cd5bdbd7 Ignore 0 attributes on dead NPCs 2 years ago
jvoisin 1a326294c0 Run IWYU on the opencs 2 years ago
psi29a da9cbbce8f add some memory 2 years ago
jvoisin cd29c181cf Another pass with IWYU 2 years ago
elsid 843753da14
Remove unused includes 2 years ago
jvoisin 3cbf1dc042 First pass with include-what-you-use 2 years ago
Evil Eye e6592aa850 Add key flag on load 2 years ago
clang-format-bot 88ec8a9523
Apply clang-format 2 years ago
Andrei Kortunov 3163d9ed56 Fix topic infos creation 2 years ago
Project579 5cf2a958eb Make conversions between std::chrono time_point and string safer by not using "localtime" directly. 2 years ago
clang-format-bot ddb0522bbf
Apply clang-format to code base 2 years ago
elsid 410a2881fe
Add comma to the last array element to prevent putting multiple elements on a single line 2 years ago
elsid 51314db2f1
Remove AI_CNDT from AI package types
AI_CNDT is a label of subrecord containing cell name. It's not AI package type.
2 years ago
elsid 52b7b66e9f
Add comma to the last array element to prevent putting multiple elements on a single line 2 years ago
elsid f269406061
Do not wrap emit expresison with parenthesis
To avoid warnings like following after clang-format applied:

apps/launcher/utils/profilescombobox.cpp:85:9: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]
    emit(signalProfileChanged(mOldProfile, currentText()));
        ^
apps/launcher/utils/profilescombobox.cpp:82:5: note: previous statement is here
    if (index == -1)
    ^
2 years ago
elsid 6ae15f08e0
Avoid chained operator() calls to prevent formatting issues 2 years ago
Project579 ca14fc00dc Added dedicated functions for conversions between QString and std::filesystem::path. 2 years ago
Project579 c226b35f1f Fix some remaining encoding errors due to std::filesystem transition. 2 years ago
Project579 a13709c510 Replace implicit convertions from std::filesystem::path to std::string with correctly converting functions. 2 years ago
Project579 4d47e8d055 openmw-cs: model: world: data: Remove dead code. 2 years ago
Project579 864112b5db Fixed Windows build when using MSVC 14.26 and MacOS build. 2 years ago
Project579 e5c417c968 Make sure all paths are passed as std::filesystem::path instead of std::string where possible. 2 years ago
Project579 35fe214588 Updated components/misc/timeconvert.hpp to fix the Android build. 2 years ago
Project579 5446571aec Circumvent QT MOC bugs by including the filesystem header in a specific order. 2 years ago
Project579 e97eeca281 Attempt to work around QT MOC bugs caused by the filesystem header. 2 years ago
Project579 4bb07282c9 Replace all remaining occurrences of boost::filesystem with std::filesystem. 2 years ago
Evil Eye fb9bc5f535 Use string_view in Fallback::Map 2 years ago
Evil Eye 2222b47e3d Make Settings::Manager::getString return a reference 2 years ago
mpeco 9040209046 functor-based Qt signal-slot syntax construction set: changing visibility of certain slots for connecting on external/derived classes 2 years ago
mpeco 78700eee57 functor-based Qt signal-slot syntax construction set 2 years ago
elsid 2a79a8074a
Use forward declarations 2 years ago
elsid b3882777ab
Cleanup opencs includes 2 years ago
elsid bf1f4f2117
Mark private template functions defined in cpp as inline 2 years ago
Alexei Kotov aee8150d65 Autoresize table subview columns (bug #6939)
Use the contents of the first 500 records, clamp the width to [100, 300]
2 years ago
Alexei Kotov e537f2b6f3 Fix display for some package settings 2 years ago
psi29a b551e69b6f #5534 remove OSG 3.4 support and require at least 3.6.5 support 2 years ago
elsid f99ed6f1db
Split components/misc/stringops.hpp into multiple headers
Replace all ciEqual overloads with one having std::string_view as argument.
2 years ago
elsid 228a0dc723
Avoid redundant lowerCase call 2 years ago
elsid ba69146ced
Use std::string_view to avoid redundant std::string construction 2 years ago
Alexei Kotov 0d18f76271 Editor: Decouple levelled list columns (bug #6705) 2 years ago
Andrei Kortunov de58c9dff3 Get rid of obsolete osg::Geode where it is possible 2 years ago
Evil Eye 3967509cdd Use meaningful names instead of pretending we don't know what snow is 2 years ago
psi29a 0eb674ec84 Merge branch 'settings_fix' into 'master'
Refactor usage of settings storage in the launcher and editor

See merge request OpenMW/openmw!2123
3 years ago
Andrei Kortunov 4b257e496e Use static settings map for launcher and editor - the Settings::Manager has a static data anyway 3 years ago
Andrei Kortunov a5b0ef0912 Avoid possible null dereference 3 years ago
Andrei Kortunov 42b9a6daaf Do not use an invalid iterator 3 years ago
elsid 7501597813
Do not use float as loop variable
apps/opencs/view/render/instanceselectionmode.cpp:294:9: warning: Variable 'i' with floating point type 'float' should not be used as a loop counter [clang-analyzer-security.FloatLoopCounter]
        for (float i = 0.0; i <= resolution; i += 2)
        ^                   ~                ~
3 years ago
elsid bef15edf0b
Remove redundant ostream, istream, iostream and sstream includes
* Replace by std::to_string and operator+ where possible.
* Move the code requiring to include <sstream> from .hpp to .cpp files.
3 years ago
Andrei Kortunov aa349f2ed9 Initialize some missing variables 3 years ago
elsid 7e6c13630a Use target_precompile_headers for the most expensive headers 3 years ago
elsid 10fbf170a2
Reduce number of includes for boost/program_options 3 years ago
Bret Curtis 37a440a0ee add one include back 3 years ago
jvoisin 8b9ed57348 Clean up Qt includes 3 years ago
psi29a 9c1970dce4 Merge branch 'lua_esm' into 'master'
Advanced Lua scripts configuration in omwaddon

See merge request OpenMW/openmw!1947
3 years ago
ζeh Matt d5ec959449
Create platform component for platform specific things 3 years ago
Petr Mikheev a70d5831c5 Lua scripts configuration in omwaddon 3 years ago
Cody Glassman ce49aa1202 Attach lights at origin when missing AttachLight node 3 years ago
Evil Eye db1a372e5b Replace new with make_unique in opencs 3 years ago
Michał Plichta 5ee5e8f2f7
Correct CS typo described in #6704 3 years ago
elsid 98f53eca65
Fix gcc warning: -Wuninitialized
/home/elsid/dev/openmw/apps/opencs/model/world/data.cpp: In constructor ‘CSMWorld::Data::Data(ToUTF8::FromType, bool, const Files::PathContainer&, const std::vector<std::__cxx11::basic_string<char> >&, const boost::filesystem::path&)’:
/home/elsid/dev/openmw/apps/opencs/model/world/data.cpp:69:36: warning: member ‘CSMWorld::Data::mCells’ is used uninitialized [-Wuninitialized]
   69 | : mEncoder (encoding), mPathgrids (mCells), mRefs (mCells),
      |                                    ^~~~~~
3 years ago
cody glassman 04843fed6d moddable post-processing pipeline 3 years ago
Evil Eye a64979e25d Replace empty std::string assignments 3 years ago
Max Henzerling 41be5a17f4 comments from PR 3 years ago
Max Henzerling af5b1b3083 Add option to open record editting subviews in new windows instead of exclusive docking. 3 years ago
Petr Mikheev c7ab67c2c1 Allow relative paths in openmw.cfg; support --replace=config. 3 years ago
elsid 0dcb1f5aac
Fix build on Windows
Use wrapper header over Windows.h to undefine far and near in a single place.
3 years ago
psi29a 84458baa8b Merge branch 'VA_OpenMW-CS' into 'master'
OpenMW-CS: Issue #3245 Add configurable instance grid, angle, and scale snapping

Closes #3245

See merge request OpenMW/openmw!1737
3 years ago
Vidi_Aquam 035fe778b2 Temporary workaround for angle snapping
Made the angle snap only apply to an object when the drag is finished, which is much more usable until the rotation system can be fixed completely
3 years ago
elsid db44f91fd5
Remove redundant include from esm3/esmreader.hpp 3 years ago
elsid 4509b05bc8
Use std::make_shared instead of new
make_shared allocates single storage for ref counter and the object.
std::shared_ptr<T>(new T) allocates 2 storages.
3 years ago
Vidi_Aquam abf0c8048e Change reading of settings and add missing logic to mouse wheel drag 3 years ago
Vidi_Aquam 6d7c8f25fc Implement grid snapping and angle snapping in OpenMW-CS
Adds configurable snap settings for instance movement, rotation and scaling, used with the secondary edit button
3 years ago
Martin Otto 96e48e5492 Make settings loader differentiate between engine and editor (fixes #6658). 3 years ago
Bret Curtis 32fd6f297a static_cast bitwise operation between different enumeration types 3 years ago